mirror of
https://github.com/tmux/tmux.git
synced 2025-01-05 23:38:48 +00:00
Do not crash if the environment variable is present but empty.
This commit is contained in:
parent
b8a9c740bb
commit
eef11b64e1
2
format.c
2
format.c
@ -1097,7 +1097,7 @@ format_find(struct format_tree *ft, const char *key, int modifiers)
|
||||
envent = environ_find(ft->s->environ, key);
|
||||
if (envent == NULL)
|
||||
envent = environ_find(global_environ, key);
|
||||
if (envent != NULL) {
|
||||
if (envent != NULL && envent->value != NULL) {
|
||||
found = xstrdup(envent->value);
|
||||
goto found;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user