Implement support for brackets in filter expressions
[lttng-tools.git] / src / common / utils.c
index 7d018b53b1b9430cfb427761f9d4b4a4573e0334..e9fb552ac1011fc37569865baacb6fdbe29ca2de 100644 (file)
@@ -755,7 +755,11 @@ static int utils_stream_file_name(char *path,
                strncpy(path, path_name_suffix, PATH_MAX - 1);
                path[PATH_MAX - 1] = '\0';
        } else {
-               strncpy(path, full_path, PATH_MAX - 1);
+               ret = lttng_strncpy(path, full_path, PATH_MAX);
+               if (ret) {
+                       ERR("Failed to copy stream file name");
+                       goto error_free_suffix;
+               }
        }
        path[PATH_MAX - 1] = '\0';
        ret = 0;
This page took 0.024287 seconds and 4 git commands to generate.