Check if interrupt action name is not null in statedump
authorSimon Marchi <simon.marchi@polymtl.ca>
Thu, 8 Nov 2012 20:17:54 +0000 (15:17 -0500)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Thu, 8 Nov 2012 20:17:54 +0000 (15:17 -0500)
Protection against poorly written drivers who give a null name to their
irq handlers.

Signed-off-by: Simon Marchi <simon.marchi@polymtl.ca>
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
instrumentation/events/lttng-module/lttng-statedump.h

index d350cad3fd45048f99b3d777266ecdf79b82b538..e4c86d659373307b232216be42f85efc590a7e65 100644 (file)
@@ -150,12 +150,12 @@ TRACE_EVENT(lttng_statedump_interrupt,
        TP_STRUCT__entry(
                __field(unsigned int, irq)
                __string(name, chip_name)
-               __string(action, action->name)
+               __string(action, action->name ? : "")
        ),
        TP_fast_assign(
                tp_assign(irq, irq)
                tp_strcpy(name, chip_name)
-               tp_strcpy(action, action->name)
+               tp_strcpy(action, action->name ? : "")
        ),
        TP_printk("")
 )
This page took 0.025616 seconds and 4 git commands to generate.