X-Git-Url: http://git.efficios.com/?p=babeltrace.git;a=blobdiff_plain;f=formats%2Fctf-text%2Fctf-text.c;h=92ad42632ece6049e5153d15325ff47a6ff14695;hp=3b38ecaca9671fe88815ea5639ef264797f3212b;hb=9ff2b8adeaadc0a8fbd8c5aa23f2cbadf2f1a55f;hpb=c50d2a7af8f63f3f4d2c0a6fce9a6e214d2baeda 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; }