# HG changeset patch # User Bram Moolenaar # Date 1544814004 -3600 # Node ID a9340baa872fdb6986eef3ad80d742c1e90bc1bd # Parent be541307f4b928a20546cae9da9fd7dcbec6c492 patch 8.1.0589: compilation error in gvimext.cpp commit https://github.com/vim/vim/commit/142a9758151e470307a80ea37b06ea34558ff5b3 Author: Bram Moolenaar Date: Fri Dec 14 19:54:39 2018 +0100 patch 8.1.0589: compilation error in gvimext.cpp Problem: Compilation error in gvimext.cpp. Solution: Return a value. Also fix using uninitialized variable. diff --git a/src/GvimExt/gvimext.cpp b/src/GvimExt/gvimext.cpp --- a/src/GvimExt/gvimext.cpp +++ b/src/GvimExt/gvimext.cpp @@ -1025,7 +1025,7 @@ STDMETHODIMP CShellExt::InvokeSingleGvim cmdlen = BUFSIZE; cmdStrW = (wchar_t *) malloc(cmdlen * sizeof(wchar_t)); if (cmdStrW == NULL) - return; + return E_FAIL; getGvimInvocationW(cmdStrW); if (useDiff) @@ -1043,7 +1043,10 @@ STDMETHODIMP CShellExt::InvokeSingleGvim cmdlen = len + BUFSIZE; wchar_t *cmdStrW_new = (wchar_t *)realloc(cmdStrW, cmdlen * sizeof(wchar_t)); if (cmdStrW_new == NULL) - goto theend; + { + free(cmdStrW); + return E_FAIL; + } cmdStrW = cmdStrW_new; } wcscat(cmdStrW, L" \""); diff --git a/src/dosinst.c b/src/dosinst.c --- a/src/dosinst.c +++ b/src/dosinst.c @@ -2459,7 +2459,7 @@ command_line_setup_choices(int argc, cha } else if (strcmp(argv[i], "-create-directories") == 0) { - int vimfiles_dir_choice; + int vimfiles_dir_choice = (int)vimfiles_dir_none; init_directories_choice(); if (argv[i + 1][0] != '-') diff --git a/src/version.c b/src/version.c --- a/src/version.c +++ b/src/version.c @@ -800,6 +800,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 589, +/**/ 588, /**/ 587,