pg_checksums: data_checksum_version is unsigned so use %u not %d
While the previous behavior didn't generate a warning, we might as well use an accurate *printf specification. Backpatch-through: 12
This commit is contained in:
parent
dffc82a5b9
commit
eec90ffbf8
@ -635,7 +635,7 @@ main(int argc, char *argv[])
|
|||||||
if (mode == PG_MODE_CHECK)
|
if (mode == PG_MODE_CHECK)
|
||||||
{
|
{
|
||||||
printf(_("Bad checksums: %s\n"), psprintf(INT64_FORMAT, badblocks));
|
printf(_("Bad checksums: %s\n"), psprintf(INT64_FORMAT, badblocks));
|
||||||
printf(_("Data checksum version: %d\n"), ControlFile->data_checksum_version);
|
printf(_("Data checksum version: %u\n"), ControlFile->data_checksum_version);
|
||||||
|
|
||||||
if (badblocks > 0)
|
if (badblocks > 0)
|
||||||
exit(1);
|
exit(1);
|
||||||
@ -662,7 +662,7 @@ main(int argc, char *argv[])
|
|||||||
update_controlfile(DataDir, ControlFile, do_sync);
|
update_controlfile(DataDir, ControlFile, do_sync);
|
||||||
|
|
||||||
if (verbose)
|
if (verbose)
|
||||||
printf(_("Data checksum version: %d\n"), ControlFile->data_checksum_version);
|
printf(_("Data checksum version: %u\n"), ControlFile->data_checksum_version);
|
||||||
if (mode == PG_MODE_ENABLE)
|
if (mode == PG_MODE_ENABLE)
|
||||||
printf(_("Checksums enabled in cluster\n"));
|
printf(_("Checksums enabled in cluster\n"));
|
||||||
else
|
else
|
||||||
|
Loading…
x
Reference in New Issue
Block a user