Browse Source

gdbinit: Avoid using a string literal in printf arguments

they do not seem to work with valgrind.
Samuel Thibault 4 years ago
parent
commit
236f9281fc
1 changed files with 5 additions and 1 deletions
  1. 5 1
      tools/gdbinit

+ 5 - 1
tools/gdbinit

@@ -317,7 +317,11 @@ define starpu-all-tasks
     while $l != &all_jobs_list
       set $j = (struct _starpu_job*) (((unsigned long) $l) - ((unsigned long) &((struct _starpu_job *)0)->all_submitted))
       set $task = $j->task
-      printf "task %p %s\n", $task, $task->name ? $task->name : ""
+      if $task->name
+        printf "task %p %s\n", $task, $task->name
+      else
+        printf "task %p\n", $task
+      end
       set $l = $l->next
     end
   end