Fix: relayd: Dereference after null check
authorFrancis Deslauriers <francis.deslauriers@efficios.com>
Tue, 1 Oct 2019 15:43:39 +0000 (11:43 -0400)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Tue, 8 Oct 2019 17:30:35 +0000 (13:30 -0400)
commit76cdeaecd77dbb124bba7021a29b2b6426f074aa
tree6954bdb610ed9ac5c83ec8f0fb971e2ffd269a19
parente27e3f4e923d0be8c04b30e6a75896ae7786435f
Fix: relayd: Dereference after null check

There is no legitimate case where a stream's trace chunk would be NULL
while receiving a data packet. It could only result from an internal
error. Hence, stream->trace_chunk != NULL can be considered a
pre-condition of this function.

Coverity report:
  CID 1404937 (#1 of 1): Dereference after null check (FORWARD_NULL)
  11. var_deref_model: Passing null pointer stream->index_file to
  relay_index_set_file, which dereferences it

Reported-by: Coverity (1404937) Dereference after null check
Signed-off-by: Francis Deslauriers <francis.deslauriers@efficios.com>
Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/bin/lttng-relayd/stream.c
This page took 0.025899 seconds and 4 git commands to generate.