summaryrefslogtreecommitdiffstats
path: root/src/gui_w48.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui_w48.c')
-rw-r--r--src/gui_w48.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gui_w48.c b/src/gui_w48.c
index be2354681e..97a0ca00ef 100644
--- a/src/gui_w48.c
+++ b/src/gui_w48.c
@@ -3500,7 +3500,10 @@ get_cmd_args(char *prog, char *cmdline, char ***argvp, char **tofree)
{
argv = (char **)malloc((argc + 1) * sizeof(char *));
if (argv == NULL )
+ {
+ vim_free(newcmdline);
return 0; /* malloc error */
+ }
pnew = newcmdline;
}
}