This is the mail archive of the glibc-cvs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

GNU C Library master sources branch master updated. glibc-2.20-255-gc82f5c0


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".

The branch, master has been updated
       via  c82f5c0ce5c1c0180fca311ceb29fd2d59da7441 (commit)
      from  439e1ad6d04e24f76f92ff7f61153fbe489559b9 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://sourceware.org/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=c82f5c0ce5c1c0180fca311ceb29fd2d59da7441

commit c82f5c0ce5c1c0180fca311ceb29fd2d59da7441
Author: Joseph Myers <joseph@codesourcery.com>
Date:   Wed Nov 26 00:45:19 2014 +0000

    Fix warning in setjmp/jmpbug.c.
    
    This patch fixes a "set but not used" warning in setjmp/jmpbug.c.  A
    variable is used only to store the result of alloca.  A cast to void
    is added to avoid the warning, and the variable is made volatile to
    ensure the call to alloca isn't optimized away for being unused.
    
    Tested for x86_64.
    
    	* setjmp/jmpbug.c (test): Make foo volatile and cast it to
    	void.

diff --git a/ChangeLog b/ChangeLog
index 23fba36..d6cedab 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2014-11-26  Joseph Myers  <joseph@codesourcery.com>
+
+	* setjmp/jmpbug.c (test): Make foo volatile and cast it to
+	void.
+
 2014-11-25  Joseph Myers  <joseph@codesourcery.com>
 
 	* stdio-common/tst-printf-round.c (test_hex_in_one_mode): Make
diff --git a/setjmp/jmpbug.c b/setjmp/jmpbug.c
index 125977b..8594c5a 100644
--- a/setjmp/jmpbug.c
+++ b/setjmp/jmpbug.c
@@ -14,7 +14,7 @@ static void
 test (int x)
 {
   jmp_buf buf;
-  char *foo;
+  char *volatile foo;
   int arr[100];
 
   arr[77] = x;
@@ -25,6 +25,7 @@ test (int x)
     }
 
   foo = (char *) alloca (128);
+  (void) foo;
   sub5 (buf);
 }
 

-----------------------------------------------------------------------

Summary of changes:
 ChangeLog       |    5 +++++
 setjmp/jmpbug.c |    3 ++-
 2 files changed, 7 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
GNU C Library master sources


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]