Fix: validate expanded path NULL ptr in relayd
authorDavid Goulet <dgoulet@efficios.com>
Mon, 25 Mar 2013 15:03:12 +0000 (11:03 -0400)
committerDavid Goulet <dgoulet@efficios.com>
Mon, 25 Mar 2013 15:03:12 +0000 (11:03 -0400)
Signed-off-by: David Goulet <dgoulet@efficios.com>
src/bin/lttng-relayd/main.c

index 00b7ea3083ad6ea95ebb35fddb5ab89ec740d790..082eb7975efd0adb1c41bfbfee65c621dd34abeb 100644 (file)
@@ -734,6 +734,10 @@ char *create_output_path_noauto(char *path_name)
        char *full_path;
 
        full_path = utils_expand_path(opt_output_path);
+       if (!full_path) {
+               goto exit;
+       }
+
        ret = asprintf(&traces_path, "%s/%s", full_path, path_name);
        if (ret < 0) {
                PERROR("asprintf trace dir name");
This page took 0.027122 seconds and 4 git commands to generate.