lib: fix compilation for glib < 2.40
authorSimon Marchi <simon.marchi@efficios.com>
Thu, 27 Jun 2019 20:03:55 +0000 (16:03 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Fri, 28 Jun 2019 19:38:29 +0000 (15:38 -0400)
Code from commit "lib: add logic in auto-seek to recreate stream state"
uses the return value of function g_hash_table_insert to validate that
the inserted key did not previously exist in the hash table.  This
feature was introduced in glib 2.40, before that the function returned
void.

To avoid breaking compatibility with glib < 2.40, we can do a lookup
before inserting to achieve the same result.

Change-Id: Ibd5f58fb6ab8f083a3152105db9e05522893132c
Signed-off-by: Simon Marchi <simon.marchi@efficios.com>
Reviewed-on: https://review.lttng.org/c/babeltrace/+/1560
Reviewed-by: Philippe Proulx <eeppeliteloop@gmail.com>

No differences found
This page took 0.024201 seconds and 4 git commands to generate.