- ret = snprintf(pathname, PATH_MAX, "%s%s%s",
- consumer->dst.trace_path, consumer->subdir, ua_sess->path);
+ ret = snprintf(pathname, LTTNG_PATH_MAX, "%s%s%s%s",
+ consumer->dst.session_root_path,
+ consumer->chunk_path,
+ consumer->subdir, ua_sess->path);