Fix: src.ctf.fs: do not use trace IR objects in queries
authorPhilippe Proulx <eeppeliteloop@gmail.com>
Wed, 27 Mar 2019 00:44:59 +0000 (20:44 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Fri, 12 Apr 2019 21:26:17 +0000 (17:26 -0400)
commitdfdc15616dca8da2d55a65050b1f6bf935ac1a6f
tree8cd3402b943dc1ef44c6f6ab61622fef74a88280
parent71446c6c8a834717cb5d3589d04cb20c3f7eef6c
Fix: src.ctf.fs: do not use trace IR objects in queries

Issue
=====
We try to create a `bt_stream` object from a translated CTF IR stream
class object (to `bt_stream_class`) systematically in
create_ds_file_groups(), but this path is also taken by the `trace-info`
query which needs DS file groups, but does not need trace IR objects
(and cannot have them because there's no self component object in this
case).

Also there's a bug in build_index_from_stream_file() where the index is
not built because of a wrong status code check.

The result is that `trace-info` query does not work.

Solution
========
Only use CTF IR objects in the queries. Therefore, only create a
`bt_stream` object for the DS file group if the CTF IR stream class was
translated (this only happens when there's an available self component).

Fix the status code check issue in build_index_from_stream_file().

Known drawbacks
===============
None.

Signed-off-by: Philippe Proulx <eeppeliteloop@gmail.com>
plugins/ctf/fs-src/data-stream-file.c
plugins/ctf/fs-src/fs.c
plugins/ctf/fs-src/fs.h
plugins/ctf/fs-src/query.c
This page took 0.026317 seconds and 5 git commands to generate.