]> sourceware.org Git - glibc.git/commitdiff
Fix sysdeps/mips/__longjmp.c warning.
authorJoseph Myers <joseph@codesourcery.com>
Wed, 26 Nov 2014 16:34:06 +0000 (16:34 +0000)
committerJoseph Myers <joseph@codesourcery.com>
Wed, 26 Nov 2014 16:34:06 +0000 (16:34 +0000)
This patch fixes

../sysdeps/mips/__longjmp.c:27:1: warning: function declaration isn't a prototype [-Wstrict-prototypes]

which arose I think from the MIPS16 changes (renaming the function to
____longjmp with an alias __longjmp, so a prior header prototype for
__longjmp no longer sufficed to prevent a warning).  I've made the
function use a prototype definition, which is what we want for all
function definitions in glibc anyway.

Tested for MIPS.

* sysdeps/mips/__longjmp.c (____longjmp): Use prototype
definition.

ChangeLog
sysdeps/mips/__longjmp.c

index 0797a15123b673079188182a3e5305b35008679c..5ec7f0d96b5743aae8fdde8bf22db1a1ce5f66b0 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2014-11-26  Joseph Myers  <joseph@codesourcery.com>
 
+       * sysdeps/mips/__longjmp.c (____longjmp): Use prototype
+       definition.
+
        * nptl/tst-cancel-self-cancelstate.c (do_test): Cast argument of
        pthread_cleanup_push to void *.
 
index 5e6a3537b48ce57489497288e7238974808d26d4..c2498c32c37acbdb7f4fcc04b734417d266bfd12 100644 (file)
@@ -24,9 +24,7 @@
 #endif
 
 static void __attribute__ ((nomips16))
-____longjmp (env_arg, val_arg)
-     __jmp_buf env_arg;
-     int val_arg;
+____longjmp (__jmp_buf env_arg, int val_arg)
 {
   /* gcc 1.39.19 miscompiled the longjmp routine (as it did setjmp before
      the hack around it); force it to use $a1 for the longjmp value.
This page took 0.11901 seconds and 5 git commands to generate.