]> granicus.if.org Git - strace/blobdiff - sysmips.c
Change last parameter of umoven() from char* to void*
[strace] / sysmips.c
index 521b08165a126d91e12d9c4de086b8be8f6474a6..6728b8a73574ce6ef9b9e0cc901ad8df2158d3bf 100644 (file)
--- a/sysmips.c
+++ b/sysmips.c
@@ -23,10 +23,14 @@ int sys_sysmips(struct tcb *tcp)
                        tprintf("%ld, %ld, %ld", tcp->u_arg[1], tcp->u_arg[2], tcp->u_arg[3]);
                } else if (tcp->u_arg[0] == SETNAME) {
                        char nodename[__NEW_UTS_LEN + 1];
-                       if (umovestr(tcp, tcp->u_arg[1], (__NEW_UTS_LEN + 1), nodename) < 0)
-                               tprintf(", %#lx", tcp->u_arg[1]);
-                       else
-                               tprintf(", \"%.*s\"", (int)(__NEW_UTS_LEN + 1), nodename);
+                       tprints(", ");
+                       if (umovestr(tcp, tcp->u_arg[1], (__NEW_UTS_LEN + 1),
+                                    nodename) < 0) {
+                               tprintf("%#lx", tcp->u_arg[1]);
+                       } else {
+                               print_quoted_string(nodename, __NEW_UTS_LEN + 1,
+                                                   QUOTE_0_TERMINATED);
+                       }
                } else if (tcp->u_arg[0] == MIPS_ATOMIC_SET) {
                        tprintf(", %#lx, 0x%lx", tcp->u_arg[1], tcp->u_arg[2]);
                } else if (tcp->u_arg[0] == MIPS_FIXADE) {