]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
mips32: fix clobbering s0 in setjmp() [BZ #22624]
authorSergei Trofimovich <slyfox@gentoo.org>
Mon, 18 Dec 2017 18:26:49 +0000 (18:26 +0000)
committerJoseph Myers <joseph@codesourcery.com>
Mon, 18 Dec 2017 18:26:49 +0000 (18:26 +0000)
Similar to commit 1ab47db00dfbc0128119e3503d3ed640ffc4830b
("mips64: fix clobbering s0 in setjmp() [BZ #22624]")
as sysdeps/mips/setjmp_aux.c is almost an identical copy
of sysdeps/mips/mips64/setjmp_aux.c.

[BZ #22624]
* sysdeps/mips/setjmp_aux.c (__sigsetjmp_aux): Use
inhibit_stack_protector.

ChangeLog
sysdeps/mips/setjmp_aux.c

index 4a7164354f2562cc66529e3c1e8ea02c1f47ff6a..31b25abb0ac4660d9d49bcdc28389207ddbbf3e3 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
 2017-12-18  Sergei Trofimovich  <slyfox@gentoo.org>
 
+       [BZ #22624]
+       * sysdeps/mips/setjmp_aux.c (__sigsetjmp_aux): Use
+       inhibit_stack_protector.
+
        [BZ #22624]
        * sysdeps/mips/mips64/setjmp_aux.c (__sigsetjmp_aux): Use
        inhibit_stack_protector.
index 0052e0c4a4d58444f075379f2c2b1099c2eea1b7..176243bc510989fc4e3018210ab4dd6f515df8b0 100644 (file)
    pointer.  We do things this way because it's difficult to reliably
    access them in C.  */
 
+/* Stack protection is disabled to avoid changing s0 (or any other
+   caller-save register) before storing it to environment.
+   See BZ #22624.  */
+
 int __attribute__ ((nomips16))
+inhibit_stack_protector
 __sigsetjmp_aux (jmp_buf env, int savemask, int sp, int fp)
 {
 #ifdef __mips_hard_float