projects
/
qemu
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7c7f537
)
fix accept(2) with NULL peer
author
Riku Voipio
<riku.voipio@nokia.com>
Fri, 16 Jan 2009 13:18:04 +0000
(15:18 +0200)
committer
Riku Voipio
<riku.voipio@nokia.com>
Fri, 16 Jan 2009 13:41:57 +0000
(15:41 +0200)
Based on scratchbox2 patch by Mika Westerberg
linux-user/syscall.c
patch
|
blob
|
history
diff --git
a/linux-user/syscall.c
b/linux-user/syscall.c
index
53167e9
..
5e0b4ae
100644
(file)
--- a/
linux-user/syscall.c
+++ b/
linux-user/syscall.c
@@
-1281,6
+1281,9
@@
static abi_long do_accept(int fd, abi_ulong target_addr,
void *addr;
abi_long ret;
+ if (target_addr == 0)
+ return get_errno(accept(fd, NULL, NULL));
+
if (get_user_u32(addrlen, target_addrlen_addr))
return -TARGET_EFAULT;