mirror of
https://github.com/izzy2lost/xemu.git
synced 2026-07-06 00:20:22 -07:00
linux-user: Make target_strerror() return 'const char *'
Make target_strerror() return 'const char *' rather than just 'char *'; this will allow us to return constant strings from it for some special cases. Signed-off-by: Peter Maydell <peter.maydell@linaro.org> Signed-off-by: Riku Voipio <riku.voipio@linaro.org> Reviewed-by: Laurent Vivier <laurent@vivier.eu>
This commit is contained in:
committed by
Riku Voipio
parent
8efb2ed5ec
commit
7dcdaeafe0
+2
-2
@@ -281,7 +281,7 @@ print_ipc(const struct syscallname *name,
|
||||
static void
|
||||
print_syscall_ret_addr(const struct syscallname *name, abi_long ret)
|
||||
{
|
||||
char *errstr = NULL;
|
||||
const char *errstr = NULL;
|
||||
|
||||
if (ret < 0) {
|
||||
errstr = target_strerror(-ret);
|
||||
@@ -1594,7 +1594,7 @@ void
|
||||
print_syscall_ret(int num, abi_long ret)
|
||||
{
|
||||
int i;
|
||||
char *errstr = NULL;
|
||||
const char *errstr = NULL;
|
||||
|
||||
for(i=0;i<nsyscalls;i++)
|
||||
if( scnames[i].nr == num ) {
|
||||
|
||||
Reference in New Issue
Block a user