mirror of
https://github.com/postgres/postgres.git
synced 2025-04-22 23:02:54 +03:00
Remove use of [U]INT64_FORMAT in some translatable strings
%lld with (long long), or %llu with (unsigned long long) are more adapted. This is similar to 3286065. Author: Kyotaro Horiguchi Discussion: https://postgr.es/m/20210421.200000.1462448394029407895.horikyota.ntt@gmail.com
This commit is contained in:
parent
bb684c82f7
commit
62aa2bb293
@ -126,8 +126,8 @@ pg_prewarm(PG_FUNCTION_ARGS)
|
|||||||
if (first_block < 0 || first_block >= nblocks)
|
if (first_block < 0 || first_block >= nblocks)
|
||||||
ereport(ERROR,
|
ereport(ERROR,
|
||||||
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
|
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
|
||||||
errmsg("starting block number must be between 0 and " INT64_FORMAT,
|
errmsg("starting block number must be between 0 and %lld",
|
||||||
nblocks - 1)));
|
(long long) (nblocks - 1))));
|
||||||
}
|
}
|
||||||
if (PG_ARGISNULL(4))
|
if (PG_ARGISNULL(4))
|
||||||
last_block = nblocks - 1;
|
last_block = nblocks - 1;
|
||||||
@ -137,8 +137,8 @@ pg_prewarm(PG_FUNCTION_ARGS)
|
|||||||
if (last_block < 0 || last_block >= nblocks)
|
if (last_block < 0 || last_block >= nblocks)
|
||||||
ereport(ERROR,
|
ereport(ERROR,
|
||||||
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
|
(errcode(ERRCODE_INVALID_PARAMETER_VALUE),
|
||||||
errmsg("ending block number must be between 0 and " INT64_FORMAT,
|
errmsg("ending block number must be between 0 and %lld",
|
||||||
nblocks - 1)));
|
(long long) (nblocks - 1))));
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Now we're ready to do the real work. */
|
/* Now we're ready to do the real work. */
|
||||||
|
@ -358,20 +358,19 @@ XLogPrefetcherFree(XLogPrefetcher *prefetcher)
|
|||||||
/* Log final statistics. */
|
/* Log final statistics. */
|
||||||
ereport(LOG,
|
ereport(LOG,
|
||||||
(errmsg("recovery finished prefetching at %X/%X; "
|
(errmsg("recovery finished prefetching at %X/%X; "
|
||||||
"prefetch = " UINT64_FORMAT ", "
|
"prefetch = %llu, "
|
||||||
"skip_hit = " UINT64_FORMAT ", "
|
"skip_hit = %llu, "
|
||||||
"skip_new = " UINT64_FORMAT ", "
|
"skip_new = %llu, "
|
||||||
"skip_fpw = " UINT64_FORMAT ", "
|
"skip_fpw = %llu, "
|
||||||
"skip_seq = " UINT64_FORMAT ", "
|
"skip_seq = %llu, "
|
||||||
"avg_distance = %f, "
|
"avg_distance = %f, "
|
||||||
"avg_queue_depth = %f",
|
"avg_queue_depth = %f",
|
||||||
(uint32) (prefetcher->reader->EndRecPtr << 32),
|
LSN_FORMAT_ARGS(prefetcher->reader->EndRecPtr),
|
||||||
(uint32) (prefetcher->reader->EndRecPtr),
|
(unsigned long long) pg_atomic_read_u64(&SharedStats->prefetch),
|
||||||
pg_atomic_read_u64(&SharedStats->prefetch),
|
(unsigned long long) pg_atomic_read_u64(&SharedStats->skip_hit),
|
||||||
pg_atomic_read_u64(&SharedStats->skip_hit),
|
(unsigned long long) pg_atomic_read_u64(&SharedStats->skip_new),
|
||||||
pg_atomic_read_u64(&SharedStats->skip_new),
|
(unsigned long long) pg_atomic_read_u64(&SharedStats->skip_fpw),
|
||||||
pg_atomic_read_u64(&SharedStats->skip_fpw),
|
(unsigned long long) pg_atomic_read_u64(&SharedStats->skip_seq),
|
||||||
pg_atomic_read_u64(&SharedStats->skip_seq),
|
|
||||||
SharedStats->avg_distance,
|
SharedStats->avg_distance,
|
||||||
SharedStats->avg_queue_depth)));
|
SharedStats->avg_queue_depth)));
|
||||||
hash_destroy(prefetcher->filter_table);
|
hash_destroy(prefetcher->filter_table);
|
||||||
|
@ -5359,8 +5359,8 @@ parseScriptWeight(const char *option, char **script)
|
|||||||
}
|
}
|
||||||
if (wtmp > INT_MAX || wtmp < 0)
|
if (wtmp > INT_MAX || wtmp < 0)
|
||||||
{
|
{
|
||||||
pg_log_fatal("weight specification out of range (0 .. %u): " INT64_FORMAT,
|
pg_log_fatal("weight specification out of range (0 .. %u): %lld",
|
||||||
INT_MAX, (int64) wtmp);
|
INT_MAX, (long long) wtmp);
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
weight = wtmp;
|
weight = wtmp;
|
||||||
@ -5680,7 +5680,7 @@ set_random_seed(const char *seed)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (seed != NULL)
|
if (seed != NULL)
|
||||||
pg_log_info("setting random seed to " UINT64_FORMAT, iseed);
|
pg_log_info("setting random seed to %llu", (unsigned long long) iseed);
|
||||||
random_seed = iseed;
|
random_seed = iseed;
|
||||||
|
|
||||||
/* Fill base_random_sequence with low-order bits of seed */
|
/* Fill base_random_sequence with low-order bits of seed */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user