]> git.xonotic.org Git - xonotic/gmqcc.git/blobdiff - exec.c
cleanups and fixes that cppcheck found
[xonotic/gmqcc.git] / exec.c
diff --git a/exec.c b/exec.c
index 6e51c027930a8a44c7dd360fd1443b029473b8c9..aaaa88b3b830fe9737c9fe7433ec36f9a186a3e4 100644 (file)
--- a/exec.c
+++ b/exec.c
@@ -644,7 +644,8 @@ static int qc_print(qc_program *prog)
     const char *laststr = NULL;
     for (i = 0; i < (size_t)prog->argc; ++i) {
         qcany *str = (qcany*)(prog->globals + OFS_PARM0 + 3*i);
-        printf("%s", (laststr = prog_getstring(prog, str->string)));
+        laststr = prog_getstring(prog, str->string);
+        printf("%s", laststr);
     }
     if (laststr && (prog->xflags & VMXF_TRACE)) {
         size_t len = strlen(laststr);