mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-14 05:53:59 +00:00
Fix for crash when setting tmux pane title
https://github.com/fish-shell/fish-shell/issues/846
This commit is contained in:
parent
464187491f
commit
220e1e8fb5
2 changed files with 1 additions and 2 deletions
|
@ -1739,7 +1739,6 @@ bool string_prefixes_string(const wchar_t *proposed_prefix, const wcstring &valu
|
||||||
return prefix_size <= value.size() && value.compare(0, prefix_size, proposed_prefix) == 0;
|
return prefix_size <= value.size() && value.compare(0, prefix_size, proposed_prefix) == 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
bool string_prefixes_string(const wcstring &proposed_prefix, const wcstring &value)
|
bool string_prefixes_string(const wcstring &proposed_prefix, const wcstring &value)
|
||||||
{
|
{
|
||||||
size_t prefix_size = proposed_prefix.size();
|
size_t prefix_size = proposed_prefix.size();
|
||||||
|
|
|
@ -289,7 +289,7 @@ static prompt_layout_t calc_prompt_layout(const wchar_t *prompt)
|
||||||
if (prompt[j+1] == L'k')
|
if (prompt[j+1] == L'k')
|
||||||
{
|
{
|
||||||
const env_var_t term_name = env_get_string(L"TERM");
|
const env_var_t term_name = env_get_string(L"TERM");
|
||||||
if (!term_name.missing() && wcsstr(term_name.c_str(), L"screen") == term_name)
|
if (!term_name.missing() && string_prefixes_string(L"screen", term_name))
|
||||||
{
|
{
|
||||||
const wchar_t *end;
|
const wchar_t *end;
|
||||||
j+=2;
|
j+=2;
|
||||||
|
|
Loading…
Reference in a new issue