1
0
forked from aniani/vim

updated for version 7.4.480

Problem:    MS-Windows: Can't build.
Solution:   Remove goto, use a flag instead.
This commit is contained in:
Bram Moolenaar
2014-10-16 16:16:37 +02:00
parent 7d76c804af
commit 799d6abf3e
2 changed files with 19 additions and 15 deletions

View File

@@ -4646,9 +4646,10 @@ mch_call_shell(
int x = 0; int x = 0;
int tmode = cur_tmode; int tmode = cur_tmode;
#ifdef FEAT_TITLE #ifdef FEAT_TITLE
char szShellTitle[512]; char szShellTitle[512];
# ifdef FEAT_MBYTE # ifdef FEAT_MBYTE
int did_set_title = FALSE;
/* Change the title to reflect that we are in a subshell. */ /* Change the title to reflect that we are in a subshell. */
if (enc_codepage >= 0 && (int)GetACP() != enc_codepage) if (enc_codepage >= 0 && (int)GetACP() != enc_codepage)
{ {
@@ -4671,25 +4672,26 @@ mch_call_shell(
wcscat(szShellTitle, wn); wcscat(szShellTitle, wn);
SetConsoleTitleW(szShellTitle); SetConsoleTitleW(szShellTitle);
vim_free(wn); vim_free(wn);
goto didset; did_set_title = TRUE;
} }
} }
} }
} }
#endif if (!did_set_title)
/* Change the title to reflect that we are in a subshell. */ # endif
if (GetConsoleTitle(szShellTitle, sizeof(szShellTitle) - 4) > 0) /* Change the title to reflect that we are in a subshell. */
{ if (GetConsoleTitle(szShellTitle, sizeof(szShellTitle) - 4) > 0)
if (cmd == NULL)
strcat(szShellTitle, " :sh");
else
{ {
strcat(szShellTitle, " - !"); if (cmd == NULL)
if ((strlen(szShellTitle) + strlen(cmd) < sizeof(szShellTitle))) strcat(szShellTitle, " :sh");
strcat(szShellTitle, cmd); else
{
strcat(szShellTitle, " - !");
if ((strlen(szShellTitle) + strlen(cmd) < sizeof(szShellTitle)))
strcat(szShellTitle, cmd);
}
SetConsoleTitle(szShellTitle);
} }
SetConsoleTitle(szShellTitle);
}
#endif #endif
out_flush(); out_flush();

View File

@@ -741,6 +741,8 @@ static char *(features[]) =
static int included_patches[] = static int included_patches[] =
{ /* Add new patch number below this line */ { /* Add new patch number below this line */
/**/
480,
/**/ /**/
479, 479,
/**/ /**/