Cleanup: Remove unneeded local variables from function
[babeltrace.git] / formats / ctf / events.c
index be90d841acbcc5bc05fbc6a6bf1dda2423a15008..15882eeffd20c2400de32af077e2879402165095 100644 (file)
@@ -255,16 +255,11 @@ struct bt_context *bt_ctf_event_get_context(const struct bt_ctf_event *event)
 {
        struct bt_context *ret = NULL;
        struct ctf_file_stream *cfs;
-       struct ctf_stream *stream;
-       struct ctf_stream_class *stream_class;
        struct ctf_trace *trace;
 
        cfs = container_of(event->stream, struct ctf_file_stream,
                        parent);
-       stream = &cfs->parent;
-       stream_class = stream->stream_class;
-       trace = stream_class->trace;
-
+       trace = cfs->parent.stream_class->trace;
        if (trace->ctx)
                ret = trace->ctx;
 
@@ -275,16 +270,11 @@ int bt_ctf_event_get_handle_id(const struct bt_ctf_event *event)
 {
        int ret = -1;
        struct ctf_file_stream *cfs;
-       struct ctf_stream *stream;
-       struct ctf_stream_class *stream_class;
        struct ctf_trace *trace;
 
        cfs = container_of(event->stream, struct ctf_file_stream,
                        parent);
-       stream = &cfs->parent;
-       stream_class = stream->stream_class;
-       trace = stream_class->trace;
-
+       trace = cfs->parent.stream_class->trace;
        if (trace->handle)
                ret = trace->handle->id;
 
This page took 0.023216 seconds and 4 git commands to generate.