From de477abcaaabb1f9815cb63876637a47a95e7ac1 Mon Sep 17 00:00:00 2001 From: Adhemerval Zanella Netto Date: Thu, 1 Sep 2022 10:02:30 -0300 Subject: Use '%z' instead of '%Z' on printf functions The Z modifier is a nonstandard synonymn for z (that predates z itself) and compiler might issue an warning for in invalid conversion specifier. Reviewed-by: Florian Weimer --- locale/programs/ld-collate.c | 8 ++++---- locale/programs/ld-ctype.c | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'locale') diff --git a/locale/programs/ld-collate.c b/locale/programs/ld-collate.c index 992814491d..c790623cbc 100644 --- a/locale/programs/ld-collate.c +++ b/locale/programs/ld-collate.c @@ -1059,7 +1059,7 @@ insert_value (struct linereader *ldfile, const char *symstr, size_t symlen, /* Test whether this element is not already in the list. */ if (elem->next != NULL || elem == collate->cursor) { - lr_error (ldfile, _("order for `%.*s' already defined at %s:%Zu"), + lr_error (ldfile, _("order for `%.*s' already defined at %s:%zu"), (int) symlen, symstr, elem->file, elem->line); lr_ignore_rest (ldfile, 0); return 1; @@ -1235,7 +1235,7 @@ range is not lower than that of the last character"), "LC_COLLATE"); && elem->next == collate->cursor)) { lr_error (ldfile, _("\ -order for `%.*s' already defined at %s:%Zu"), +order for `%.*s' already defined at %s:%zu"), (int) namelen, seq->name, elem->file, elem->line); goto increment; @@ -1378,7 +1378,7 @@ order for `%.*s' already defined at %s:%Zu"), && elem->next == collate->cursor)) { lr_error (ldfile, _("\ -%s: order for `%.*s' already defined at %s:%Zu"), +%s: order for `%.*s' already defined at %s:%zu"), "LC_COLLATE", (int) lenfrom, buf, elem->file, elem->line); continue; @@ -3728,7 +3728,7 @@ error while adding equivalent collating symbol")); || &collate->undefined == collate->cursor) { lr_error (ldfile, - _("%s: order for `%.*s' already defined at %s:%Zu"), + _("%s: order for `%.*s' already defined at %s:%zu"), "LC_COLLATE", 9, "UNDEFINED", collate->undefined.file, collate->undefined.line); diff --git a/locale/programs/ld-ctype.c b/locale/programs/ld-ctype.c index c6749dbd82..e85820d335 100644 --- a/locale/programs/ld-ctype.c +++ b/locale/programs/ld-ctype.c @@ -526,7 +526,7 @@ internal error in %s, line %u"), __FUNCTION__, __LINE__); { char buf[17]; - snprintf (buf, sizeof buf, "\\%Zo", cnt); + snprintf (buf, sizeof buf, "\\%zo", cnt); record_error (0, 0, _("\ character '%s' in class `%s' must be in class `%s'"), @@ -541,7 +541,7 @@ character '%s' in class `%s' must be in class `%s'"), { char buf[17]; - snprintf (buf, sizeof buf, "\\%Zo", cnt); + snprintf (buf, sizeof buf, "\\%zo", cnt); record_error (0, 0, _("\ character '%s' in class `%s' must not be in class `%s'"), -- cgit 1.4.1