diff options
author | Manuel Novoa III <mjn3@codepoet.org> | 2005-07-23 14:02:57 +0000 |
---|---|---|
committer | Manuel Novoa III <mjn3@codepoet.org> | 2005-07-23 14:02:57 +0000 |
commit | 47167cdc5d0ef7fbbb1a0c65934e0fa8acb89833 (patch) | |
tree | 31a1f7f47478229a6590b0e18c5126d9c942ed3b /libc/sysdeps/linux | |
parent | 2433f86b14f64cf012b687daf56fe24bb2c30a68 (diff) |
Since __syscall_error is a C func, we need to store the syscall return value
in the appropriate register. Otherwise, errno is set to random garbage.
Diffstat (limited to 'libc/sysdeps/linux')
-rw-r--r-- | libc/sysdeps/linux/mips/clone.S | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libc/sysdeps/linux/mips/clone.S b/libc/sysdeps/linux/mips/clone.S index 3b879040a..079d2bef2 100644 --- a/libc/sysdeps/linux/mips/clone.S +++ b/libc/sysdeps/linux/mips/clone.S @@ -72,6 +72,11 @@ __clone: /* Something bad happened -- no child created */ error: addiu sp,32 + + /* uClibc change -- start */ + move a0,v0 /* Pass return val to C function. */ + /* uClibc change -- stop */ + #ifdef __PIC__ la t9,__syscall_error jr t9 |