tools lib traceevent: Avoid comparisions between signed/unsigned
authorArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 9 Nov 2012 18:32:00 +0000 (15:32 -0300)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Fri, 9 Nov 2012 20:34:58 +0000 (17:34 -0300)
Fixing this warning-as-error on f14 32-bit:

  tools/lib/traceevent/event-parse.c:5564:17: error: comparison between signed and unsigned integer expressions
  tools/lib/traceevent/event-parse.c:5586:17: error: comparison between signed and unsigned integer expressions

Cc: David Ahern <dsahern@gmail.com>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Stephane Eranian <eranian@google.com>
Cc: Steven Rostedt <rostedt@goodmis.org>
Link: http://lkml.kernel.org/n/tip-stmix8hy4nu5ervpynn8yj2z@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/lib/traceevent/event-parse.c

index 0dcc18c..6b647c1 100644 (file)
@@ -5561,7 +5561,7 @@ void pevent_free(struct pevent *pevent)
        }
 
        if (pevent->func_map) {
-               for (i = 0; i < pevent->func_count; i++) {
+               for (i = 0; i < (int)pevent->func_count; i++) {
                        free(pevent->func_map[i].func);
                        free(pevent->func_map[i].mod);
                }
@@ -5583,7 +5583,7 @@ void pevent_free(struct pevent *pevent)
        }
 
        if (pevent->printk_map) {
-               for (i = 0; i < pevent->printk_count; i++)
+               for (i = 0; i < (int)pevent->printk_count; i++)
                        free(pevent->printk_map[i].printk);
                free(pevent->printk_map);
        }