From: Peter Eisentraut Date: Fri, 25 Apr 2025 14:49:30 +0000 (+0200) Subject: Fix incorrect format placeholders X-Git-Tag: REL_18_BETA1~85 X-Git-Url: http://git.postgresql.org/gitweb/?a=commitdiff_plain;h=76d52e71659149d20d616c8a94c02793cedce066;p=postgresql.git Fix incorrect format placeholders Before commit a0ed19e0a9e there was a cast around these, but the cast inadvertently changed the signedness, but that made the format placeholder correct. Commit a0ed19e0a9e removed the casts, so now the format placeholders had the wrong signedness. --- diff --git a/src/fe_utils/print.c b/src/fe_utils/print.c index 28d5bb0bd5d..4af0f32f2fc 100644 --- a/src/fe_utils/print.c +++ b/src/fe_utils/print.c @@ -3185,7 +3185,7 @@ printTableInit(printTableContent *const content, const printTableOpt *opt, /* Catch possible overflow. Using >= here allows adding 1 below */ if (total_cells >= SIZE_MAX / sizeof(*content->cells)) { - fprintf(stderr, _("Cannot print table contents: number of cells %" PRId64 " is equal to or exceeds maximum %zu.\n"), + fprintf(stderr, _("Cannot print table contents: number of cells %" PRIu64 " is equal to or exceeds maximum %zu.\n"), total_cells, SIZE_MAX / sizeof(*content->cells)); exit(EXIT_FAILURE); @@ -3269,7 +3269,7 @@ printTableAddCell(printTableContent *const content, char *cell, total_cells = (uint64) content->ncolumns * content->nrows; if (content->cellsadded >= total_cells) { - fprintf(stderr, _("Cannot add cell to table content: total cell count of %" PRId64 " exceeded.\n"), + fprintf(stderr, _("Cannot add cell to table content: total cell count of %" PRIu64 " exceeded.\n"), total_cells); exit(EXIT_FAILURE); }