Fix: compat: -ust suffix sprintf error handling
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 12 Sep 2016 22:58:50 +0000 (18:58 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Mon, 12 Sep 2016 22:59:21 +0000 (18:59 -0400)
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
liblttng-ust/compat.h

index cd83b46ba8e4000dc901f2e5adddca8debf59977..003b480aa01d27dc428877dc9935963335e5340d 100644 (file)
@@ -110,7 +110,7 @@ int lttng_ust_setustprocname(void)
        }
 
        ret = sprintf(name + len, LTTNG_UST_PROCNAME_SUFFIX);
-       if (ret) {
+       if (ret != strlen(LTTNG_UST_PROCNAME_SUFFIX)) {
                goto error;
        }
 
This page took 0.025149 seconds and 4 git commands to generate.