From: Michael Jeanson Date: Thu, 15 Oct 2015 21:05:05 +0000 (-0400) Subject: Fix: Silence warning of function having no return value X-Git-Url: http://git.efficios.com/?p=lttng-tools.git;a=commitdiff_plain;h=2855532e5118d79661ef728cdb59dbab7857be3e Fix: Silence warning of function having no return value Some compilers complain that codepaths which assert have no return value. This is valid since assertions could be compiled-out, resulting in an undefined return value. Signed-off-by: Michael Jeanson Signed-off-by: Jérémie Galarneau --- diff --git a/src/common/mi-lttng.c b/src/common/mi-lttng.c index f0d074ea7..fc22e4e0c 100644 --- a/src/common/mi-lttng.c +++ b/src/common/mi-lttng.c @@ -397,6 +397,7 @@ const char *mi_lttng_domaintype_string(enum lttng_domain_type value) default: /* Should not have an unknown domain */ assert(0); + return NULL; } } @@ -413,6 +414,7 @@ const char *mi_lttng_buffertype_string(enum lttng_buffer_type value) default: /* Should not have an unknow buffer type */ assert(0); + return NULL; } }