mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-12-18 00:37:28 +08:00
sim: m32r: fix syslog call
The function returns void, not int. We only pass one argument to syslog (the format), so use %s as the static format instead since the emulation layer doesn't handle passing additional arguments.
This commit is contained in:
@@ -843,7 +843,8 @@ m32r_trap (SIM_CPU *current_cpu, PCADDR pc, int num)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case TARGET_LINUX_SYS_syslog:
|
case TARGET_LINUX_SYS_syslog:
|
||||||
result = syslog (arg1, (char *) t2h_addr (cb, &s, arg2));
|
syslog (arg1, "%s", (char *) t2h_addr (cb, &s, arg2));
|
||||||
|
result = 0;
|
||||||
errcode = errno;
|
errcode = errno;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user