qemu-e2k/linux-user
Peter Maydell ef4330c23b linux-user: Handle brk() attempts with very large sizes
In do_brk(), we were inadvertently truncating the size
of a requested brk() from the guest by putting it into an
'int' variable. This meant that we would incorrectly report
success back to the guest rather than a failed allocation,
typically resulting in the guest then segfaulting. Use
abi_ulong instead.

This fixes a crash in the '31370.cc' test in the gcc libstdc++ test
suite (the test case starts by trying to allocate a very large
size and reduces the size until the allocation succeeds).

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Riku Voipio <riku.voipio@linaro.org>
2016-08-04 16:38:17 +03:00
..
aarch64 linux-user: AArch64 has sync_file_range, not sync_file_range2 2016-07-19 16:18:11 +03:00
alpha linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
arm Clean up ill-advised or unusual header guards 2016-07-12 16:20:46 +02:00
cris linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
host linux-user: Clean up hostdep.h header guards 2016-07-12 16:19:16 +02:00
i386 linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
m68k linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
microblaze linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
mips linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
mips64
openrisc linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
ppc linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
s390x linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
sh4 linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
sparc linux-user: define missing sparc syscalls 2016-07-19 16:18:11 +03:00
sparc64 linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
tilegx Clean up ill-advised or unusual header guards 2016-07-12 16:20:46 +02:00
unicore32 linux-user: Clean up target_structs.h header guards 2016-07-12 16:19:16 +02:00
x86_64 linux-user: Fix target_semid_ds structure definition 2016-08-04 16:36:53 +03:00
elfload.c
errno_defs.h
flat.h
flatload.c
ioctls.h linux-user: Fix type for SIOCATMARK ioctl 2016-07-19 16:18:11 +03:00
linux_loop.h linux-user: Add loop control ioctls 2016-07-19 15:22:33 +03:00
linuxload.c
m68k-sim.c
main.c trace: Add per-vCPU tracing states for events with the 'vcpu' property 2016-07-18 18:23:12 +01:00
Makefile.objs
mmap.c
qemu.h exec: Reduce CONFIG_USER_ONLY ifdeffenery 2016-07-26 15:31:58 -03:00
safe-syscall.S
signal.c linux-user: Forget about synchronous signal once it is delivered 2016-07-19 15:23:16 +03:00
socket.h
strace.c
strace.list
syscall_defs.h linux-user: Add some new blk ioctls 2016-07-19 15:23:17 +03:00
syscall_types.h linux-user: Correct type for LOOP_GET_STATUS{,64} ioctls 2016-07-19 15:23:16 +03:00
syscall.c linux-user: Handle brk() attempts with very large sizes 2016-08-04 16:38:17 +03:00
target_flat.h
trace-events
uaccess.c
uname.c
uname.h Clean up decorations and whitespace around header guards 2016-07-12 16:20:46 +02:00
vm86.c