mirror of
https://github.com/tmux/tmux.git
synced 2026-03-06 07:45:35 +00:00
Fix memory leak, from Chris Lewis, reported by Huihui Huang.
This commit is contained in:
1
file.c
1
file.c
@@ -58,6 +58,7 @@ file_get_path(struct client *c, const char *file)
|
|||||||
if (*path == '/')
|
if (*path == '/')
|
||||||
return (path);
|
return (path);
|
||||||
xasprintf(&full_path, "%s/%s", server_client_get_cwd(c, NULL), path);
|
xasprintf(&full_path, "%s/%s", server_client_get_cwd(c, NULL), path);
|
||||||
|
free(path);
|
||||||
return (full_path);
|
return (full_path);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user