Blame SOURCES/glibc-rh1505492-types-5.patch
|
|
00db10 |
commit be97091638d156a53009b4034c60b58eaf3efa24
|
|
|
00db10 |
Author: Joseph Myers <joseph@codesourcery.com>
|
|
|
00db10 |
Date: Thu Nov 27 03:24:18 2014 +0000
|
|
|
00db10 |
|
|
|
00db10 |
Fix nss/tst-nss-test1.c format warning.
|
|
|
00db10 |
|
|
|
00db10 |
Testing for 32-bit x86 shows up a warning "tst-nss-test1.c:25:3:
|
|
|
00db10 |
warning: format '%ju' expects argument of type 'uintmax_t', but
|
|
|
00db10 |
argument 2 has type 'int' [-Wformat=]". The argument is a difference
|
|
|
00db10 |
of two pointers, a signed quantity of type ptrdiff_t for which the
|
|
|
00db10 |
right format is %td; this patch makes this test use that format.
|
|
|
00db10 |
|
|
|
00db10 |
Tested for 32-bit x86.
|
|
|
00db10 |
|
|
|
00db10 |
* nss/tst-nss-test1.c (do_test): Use %td printf format for pointer
|
|
|
00db10 |
difference, not %ju.
|
|
|
00db10 |
|
|
|
00db10 |
diff --git a/nss/tst-nss-test1.c b/nss/tst-nss-test1.c
|
|
|
00db10 |
index 4e443d453909e231..c5750e0956ea9450 100644
|
|
|
00db10 |
--- a/nss/tst-nss-test1.c
|
|
|
00db10 |
+++ b/nss/tst-nss-test1.c
|
|
|
00db10 |
@@ -21,7 +21,7 @@ do_test (void)
|
|
|
00db10 |
if (p->pw_uid != *np || strncmp (p->pw_name, "name", 4) != 0
|
|
|
00db10 |
|| atol (p->pw_name + 4) != *np)
|
|
|
00db10 |
{
|
|
|
00db10 |
- printf ("passwd entry %ju wrong (%s, %u)\n",
|
|
|
00db10 |
+ printf ("passwd entry %td wrong (%s, %u)\n",
|
|
|
00db10 |
np - pwdids, p->pw_name, p->pw_uid);
|
|
|
00db10 |
retval = 1;
|
|
|
00db10 |
break;
|