Fix: cmd_snapshot_record can return unexpected error codes
authorJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 16 Nov 2018 21:46:36 +0000 (16:46 -0500)
committerJérémie Galarneau <jeremie.galarneau@efficios.com>
Fri, 16 Nov 2018 21:52:08 +0000 (16:52 -0500)
commit9a6545985844978f34f88b82bf1bcd649968c0a3
tree27aecc61ef87612b67b744239d1c599126137f1a
parent45798a31cc31b86a669221676ab490c035c8dfdd
Fix: cmd_snapshot_record can return unexpected error codes

cmd_snapshot_record() does not correctly handle the various error
reporting conventions used by the functions it uses. In certain cases,
invalid error codes (not part of enum lttng_error_code) can bubble up
to the command handler which results in erroneous error messages being
reported by the client.

This change harmonizes the error handling and changes a number of
functions used to explicitly return 'enum lttng_error_code' instead
of 'int'.

Signed-off-by: Jérémie Galarneau <jeremie.galarneau@efficios.com>
src/bin/lttng-sessiond/cmd.c
src/bin/lttng-sessiond/consumer.c
src/bin/lttng-sessiond/consumer.h
src/bin/lttng-sessiond/kernel.c
src/bin/lttng-sessiond/kernel.h
src/bin/lttng-sessiond/ust-app.c
src/bin/lttng-sessiond/ust-app.h
This page took 0.026681 seconds and 4 git commands to generate.