From: Joseph Myers Date: Tue, 25 Nov 2014 21:40:51 +0000 (+0000) Subject: Fix warning in posix/bug-regex31.c. X-Git-Tag: glibc-2.21~331 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=bde2667a22c355467a4f07246c6d07a9dcc89366;p=thirdparty%2Fglibc.git Fix warning in posix/bug-regex31.c. This patch fixes a "set but not used" warning in posix/bug-regex31.c. A variable res stored an indication of whether the test behaved as expected, but was then ignored and the test returned 0 unconditionally (as an mtrace test, the auxiliary test for leaks could still have failed if that bug was present). This patch makes the test return res. Tested for x86_64. * posix/bug-regex31.c (main): Return RES not 0. --- diff --git a/ChangeLog b/ChangeLog index f827c3abf64..8ee0650df73 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2014-11-25 Joseph Myers + + * posix/bug-regex31.c (main): Return RES not 0. + 2014-11-25 Anton Blanchard * sysdeps/powerpc/bits/atomic.h diff --git a/posix/bug-regex31.c b/posix/bug-regex31.c index fc485815fcf..fd7e0c57cab 100644 --- a/posix/bug-regex31.c +++ b/posix/bug-regex31.c @@ -33,5 +33,5 @@ main (void) free (buf); - return 0; + return res; }