Fix commandline handling for ARM semihosted executables
authorWolfgang Schildbach <wschi@dolby.com>
Mon, 6 Dec 2010 15:06:05 +0000 (15:06 +0000)
committerRiku Voipio <riku.voipio@iki.fi>
Fri, 7 Jan 2011 16:20:48 +0000 (18:20 +0200)
commitfd6fb8cba0c7d9a46bc6d6e72668b1a4afeecf19
tree3ed47324b6182cf419fbde9de0db436dcb57fae2
parentda2040215785d493bcabfd1af0dc2ee8a7f7e8cc
Fix commandline handling for ARM semihosted executables

Use the copy of the command line that loader_build_argptr() sets up in guest
memory as the command line to return from the ARM SYS_GET_CMDLINE semihosting
call. Previously we were using a pointer to memory which had already been
freed before the guest program started.

This fixes https://bugs.launchpad.net/qemu/+bug/673613 .

Signed-off-by: Wolfgang Schildbach <wschi@dolby.com>
Reviewed-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Riku Voipio <riku.voipio@iki.fi>
arm-semi.c