mirror of
https://github.com/tmate-io/tmate.git
synced 2024-11-23 08:33:17 +01:00
Don't try to free old string values (and crash) when they are overridden unless
they were actually found in the source terminal description. Reported by jmc.
This commit is contained in:
parent
9a391b3320
commit
ac54dee9bb
@ -196,6 +196,7 @@ tty_term_override(struct tty_term *term, const char *overrides)
|
||||
case TTYCODE_NONE:
|
||||
break;
|
||||
case TTYCODE_STRING:
|
||||
if (code->type == TTYCODE_STRING)
|
||||
xfree(code->value.string);
|
||||
code->value.string = xstrdup(val);
|
||||
code->type = ent->type;
|
||||
|
Loading…
Reference in New Issue
Block a user