From 39b346d1ea0c3305d9a5ab74fb38f6a64a01ef73 Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Sat, 17 Dec 2011 23:46:47 +0000 Subject: In usr.sbin/pw/pw_user.c, use the correct printf length modifier for a ptrdiff_t. MFC after: 1 week --- pw/pw_user.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pw/pw_user.c b/pw/pw_user.c index db33746..0001a41 100644 --- a/pw/pw_user.c +++ b/pw/pw_user.c @@ -1208,7 +1208,7 @@ pw_checkname(u_char *name, int gecos) if (reject) { snprintf(showch, sizeof(showch), (*ch >= ' ' && *ch < 127) ? "`%c'" : "0x%02x", *ch); - errx(EX_DATAERR, "invalid character %s at position %d in %s", + errx(EX_DATAERR, "invalid character %s at position %td in %s", showch, (ch - name), showtype); } if (!gecos && (ch - name) > LOGNAMESIZE) -- cgit v1.2.3