From: Fredrik Oestman Date: Tue, 3 Apr 2012 12:55:42 +0000 (-0400) Subject: Babeltrace ctf-text duplicated error message X-Git-Tag: v1.0.0-rc1~14 X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=commitdiff_plain;h=9ff2b8adeaadc0a8fbd8c5aa23f2cbadf2f1a55f;hp=c50d2a7af8f63f3f4d2c0a6fce9a6e214d2baeda Babeltrace ctf-text duplicated error message Signed-off-by: Mathieu Desnoyers --- diff --git a/formats/ctf-text/ctf-text.c b/formats/ctf-text/ctf-text.c index 3b38ecac..92ad4263 100644 --- a/formats/ctf-text/ctf-text.c +++ b/formats/ctf-text/ctf-text.c @@ -236,8 +236,8 @@ int ctf_text_write_event(struct stream_pos *ppos, struct ctf_stream_definition * return -EINVAL; } event_class = g_ptr_array_index(stream_class->events_by_id, id); - if (!event) { - fprintf(stderr, "[error] Event id %" PRIu64 " is unknown.\n", id); + if (!event_class) { + fprintf(stderr, "[error] Event class id %" PRIu64 " is unknown.\n", id); return -EINVAL; }