From afa0ed124ffe0a932e40ba4b68e8571be2fcc599 Mon Sep 17 00:00:00 2001 From: James Vega Date: Sun, 14 Oct 2007 04:43:58 +1000 Subject: [PATCH] Check whether '$TERM' starts with 'screen' instead of whether it's an exact match when determining if \ek\e\\ should be recognized. There are various terminfo entries for screen that should be recognized aside from simply 'screen' such as 'screen-256color' and 'screen-bce'. darcs-hash:20071013184358-35ec8-5e85add3cc1667781590e12118a98ec6641bc714.gz --- screen.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/screen.c b/screen.c index 33d9811ce..60b69f62c 100644 --- a/screen.c +++ b/screen.c @@ -201,7 +201,7 @@ static int calc_prompt_width( wchar_t *prompt ) if( prompt[j+1] == L'k' ) { wchar_t *term_name = env_get( L"TERM" ); - if( term_name && wcscmp( term_name, L"screen" ) == 0 ) + if( term_name && wcsstr( term_name, L"screen" ) == term_name ) { wchar_t *end; j+=2;