mirror of
https://github.com/tmux/tmux.git
synced 2024-11-17 18:08:51 +00:00
Trim "s from process names, from Gregory Pakosz.
This commit is contained in:
parent
4f638c0e31
commit
5f50e7d942
4
names.c
4
names.c
@ -142,6 +142,10 @@ parse_window_name(const char *in)
|
|||||||
char *copy, *name, *ptr;
|
char *copy, *name, *ptr;
|
||||||
|
|
||||||
name = copy = xstrdup(in);
|
name = copy = xstrdup(in);
|
||||||
|
if (*name == '"')
|
||||||
|
name++;
|
||||||
|
name[strcspn (name, "\"")] = '\0';
|
||||||
|
|
||||||
if (strncmp(name, "exec ", (sizeof "exec ") - 1) == 0)
|
if (strncmp(name, "exec ", (sizeof "exec ") - 1) == 0)
|
||||||
name = name + (sizeof "exec ") - 1;
|
name = name + (sizeof "exec ") - 1;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user