From a0ed19e0a9efe93b3b83d6e3fe8f77656be253a2 Mon Sep 17 00:00:00 2001 From: Peter Eisentraut Date: Sat, 29 Mar 2025 10:30:08 +0100 Subject: Use PRI?64 instead of "ll?" in format strings (continued). Continuation of work started in commit 15a79c73, after initial trial. Author: Thomas Munro Discussion: https://postgr.es/m/b936d2fb-590d-49c3-a615-92c3a88c6c19%40eisentraut.org --- contrib/pageinspect/btreefuncs.c | 6 ++---- contrib/pageinspect/hashfuncs.c | 4 ++-- 2 files changed, 4 insertions(+), 6 deletions(-) (limited to 'contrib/pageinspect') diff --git a/contrib/pageinspect/btreefuncs.c b/contrib/pageinspect/btreefuncs.c index 9cdc8e182b4..294821231fc 100644 --- a/contrib/pageinspect/btreefuncs.c +++ b/contrib/pageinspect/btreefuncs.c @@ -206,14 +206,12 @@ check_relation_block_range(Relation rel, int64 blkno) if (blkno < 0 || blkno > MaxBlockNumber) ereport(ERROR, (errcode(ERRCODE_INVALID_PARAMETER_VALUE), - errmsg("invalid block number %lld", - (long long) blkno))); + errmsg("invalid block number %" PRId64, blkno))); if ((BlockNumber) (blkno) >= RelationGetNumberOfBlocks(rel)) ereport(ERROR, (errcode(ERRCODE_INVALID_PARAMETER_VALUE), - errmsg("block number %lld is out of range", - (long long) blkno))); + errmsg("block number %" PRId64 " is out of range", blkno))); } /* ----------------------------------------------- diff --git a/contrib/pageinspect/hashfuncs.c b/contrib/pageinspect/hashfuncs.c index d4a2a1d676a..ca7f1f6e741 100644 --- a/contrib/pageinspect/hashfuncs.c +++ b/contrib/pageinspect/hashfuncs.c @@ -436,8 +436,8 @@ hash_bitmap_info(PG_FUNCTION_ARGS) if (ovflblkno >= RelationGetNumberOfBlocks(indexRel)) ereport(ERROR, (errcode(ERRCODE_INVALID_PARAMETER_VALUE), - errmsg("block number %lld is out of range for relation \"%s\"", - (long long int) ovflblkno, RelationGetRelationName(indexRel)))); + errmsg("block number %" PRId64 " is out of range for relation \"%s\"", + ovflblkno, RelationGetRelationName(indexRel)))); /* Read the metapage so we can determine which bitmap page to use */ metabuf = _hash_getbuf(indexRel, HASH_METAPAGE, HASH_READ, LH_META_PAGE); -- cgit v1.2.3