diff mbox series

[v7,48/74] linux-user: Fix types in ioctl logging

Message ID 20190519203726.20729-49-richard.henderson@linaro.org
State New
Headers show
Series linux-user: Split do_syscall | expand

Commit Message

Richard Henderson May 19, 2019, 8:37 p.m. UTC
There is no need to cast "int" to "long"; just use the
correct format in the first place.

Signed-off-by: Richard Henderson <richard.henderson@linaro.org>

---
 linux-user/syscall-ioctl.inc.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

-- 
2.17.1
diff mbox series

Patch

diff --git a/linux-user/syscall-ioctl.inc.c b/linux-user/syscall-ioctl.inc.c
index be3f0b4b92..15d87b9663 100644
--- a/linux-user/syscall-ioctl.inc.c
+++ b/linux-user/syscall-ioctl.inc.c
@@ -791,7 +791,7 @@  SYSCALL_IMPL(ioctl)
 
     for (ie = ioctl_entries; ; ie++) {
         if (ie->target_cmd == 0) {
-            gemu_log("Unsupported ioctl: cmd=0x%04lx\n", (long)cmd);
+            gemu_log("Unsupported ioctl: cmd=0x%04x\n", cmd);
             return -TARGET_ENOSYS;
         }
         if (ie->target_cmd == cmd) {
@@ -864,8 +864,8 @@  SYSCALL_IMPL(ioctl)
         }
         break;
     default:
-        gemu_log("Unsupported ioctl type: cmd=0x%04lx type=%d\n",
-                 (long)cmd, arg_type[0]);
+        gemu_log("Unsupported ioctl type: cmd=0x%04x type=%d\n",
+                 cmd, arg_type[0]);
         ret = -TARGET_ENOSYS;
         break;
     }