From: Eli Zaretskii Date: Sun, 5 May 2019 14:17:24 +0000 (+0300) Subject: Avoid compiler warning in print.c X-Git-Tag: emacs-27.0.90~2979 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=d45d5c339cda613b70431ab51af7ee53f21ef4bf;p=emacs.git Avoid compiler warning in print.c * src/print.c (print_vectorlike): Don't use %hh, as that is not portable enough; we don't yet assume a C99-compliant library. --- diff --git a/src/print.c b/src/print.c index 57aac5f5471..08c39d34664 100644 --- a/src/print.c +++ b/src/print.c @@ -1808,7 +1808,7 @@ print_vectorlike (Lisp_Object obj, Lisp_Object printcharfun, bool escapeflag, enum { digits = (CHAR_BIT + 4 - 1) / 4 }; char buffer[digits + 1]; int needed - = snprintf (buffer, sizeof buffer, "%0*hhx", digits, b); + = snprintf (buffer, sizeof buffer, "%0*x", digits, b); eassert (needed == digits); print_c_string (buffer, printcharfun); }