summaryrefslogtreecommitdiffstats
path: root/lib/libc/i386/gen
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2003-05-07 17:23:25 +0000
committerjhb <jhb@FreeBSD.org>2003-05-07 17:23:25 +0000
commit166330230a2277d4ff5ff2f7f1d0977d1af26ecb (patch)
treec273710c8ce48a6d9a9a1701e75680ab0c4e2b84 /lib/libc/i386/gen
parent905e807e482c4a0adf713a258dff19a0ed4134c8 (diff)
downloadFreeBSD-src-166330230a2277d4ff5ff2f7f1d0977d1af26ecb.zip
FreeBSD-src-166330230a2277d4ff5ff2f7f1d0977d1af26ecb.tar.gz
Properly cleanup the stack before jumping to cerror() if rfork(2) fails.
Submitted by: Igor Sysoev <is@rambler-co.ru> Approved by: re (scottl)
Diffstat (limited to 'lib/libc/i386/gen')
-rw-r--r--lib/libc/i386/gen/rfork_thread.S4
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/libc/i386/gen/rfork_thread.S b/lib/libc/i386/gen/rfork_thread.S
index d01aebe..c0fc624 100644
--- a/lib/libc/i386/gen/rfork_thread.S
+++ b/lib/libc/i386/gen/rfork_thread.S
@@ -109,5 +109,9 @@ ENTRY(rfork_thread)
* Branch here if the thread creation fails:
*/
2:
+ addl $8, %esp
+ popl %esi
+ movl %ebp, %esp
+ popl %ebp
PIC_PROLOGUE
jmp PIC_PLT(HIDENAME(cerror))
OpenPOWER on IntegriCloud