Fix: muxer: check for MUXER_MSG_ITER_CLOCK_CLASS_EXPECTATION_NONE in validate_new_str...
authorSimon Marchi <simon.marchi@efficios.com>
Fri, 9 Aug 2019 20:30:09 +0000 (16:30 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Sat, 10 Aug 2019 17:36:51 +0000 (13:36 -0400)
commit9244b07ab1598e27d633136124409fff7dd75ff7
treedfaf975c7d5fa51804af52011a2795f2a8749a7c
parent2b950395ddd2aaee36d0be59ed303826bceb0193
Fix: muxer: check for MUXER_MSG_ITER_CLOCK_CLASS_EXPECTATION_NONE in validate_new_stream_clock_class

There is a problem currently when trying to send multiple streams that
don't have a clock class (which is a supported use case) to a muxer
instance.

The first time we enter validate_new_stream_clock_class without a clock
class, we set the expectation to
MUXER_MSG_ITER_CLOCK_CLASS_EXPECTATION_NONE.  The second time we enter
without a clock class, we wrongfully go to the error case.  We are
missing a check for MUXER_MSG_ITER_CLOCK_CLASS_EXPECTATION_NONE, which
is the expected and valid case.  This patch adds it.

Also, the error message is erroneous.  If we are in that situation, we
expect a stream class _without_ a clock class, but are met with a stream
class _with_ a clock class.  Fix that at the same time.

Change-Id: Iea692578498ea87a33ecba5d2fd54b2980056cd0
Signed-off-by: Simon Marchi <simon.marchi@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1862
CI-Build: Philippe Proulx <eeppeliteloop@gmail.com>
Tested-by: jenkins <jenkins@lttng.org>
Reviewed-by: Philippe Proulx <eeppeliteloop@gmail.com>
src/plugins/utils/muxer/muxer.c
This page took 0.025497 seconds and 4 git commands to generate.