summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-02-01 21:47:13 +0100
committerBram Moolenaar <Bram@vim.org>2016-02-01 21:47:13 +0100
commit14ad611ca435d97e8fd0d9ab03ddc982843298ac (patch)
tree512d647ad0f0d4a1ce179f28236c89bfd0b0579d /src
parent1357caf31f3e447d99baf8dd6a3243e2ab38567f (diff)
downloadvim-14ad611ca435d97e8fd0d9ab03ddc982843298ac.zip
patch 7.4.1233
Problem: Channel command may cause a crash. Solution: Check for NULL argument. (Damien)
Diffstat (limited to 'src')
-rw-r--r--src/channel.c4
-rw-r--r--src/version.c2
2 files changed, 5 insertions, 1 deletions
diff --git a/src/channel.c b/src/channel.c
index f32925097..8cb9a352e 100644
--- a/src/channel.c
+++ b/src/channel.c
@@ -629,6 +629,8 @@ channel_exe_cmd(int idx, char_u *cmd, typval_T *arg2, typval_T *arg3)
return;
}
arg = arg2->vval.v_string;
+ if (arg == NULL)
+ arg = (char_u *)"";
if (STRCMP(cmd, "ex") == 0)
{
@@ -647,7 +649,7 @@ channel_exe_cmd(int idx, char_u *cmd, typval_T *arg2, typval_T *arg3)
{
exarg_T ea;
- ea.forceit = arg != NULL && *arg != NUL;
+ ea.forceit = *arg != NUL;
ex_redraw(&ea);
showruler(FALSE);
setcursor();
diff --git a/src/version.c b/src/version.c
index 04231004f..1bb4030f9 100644
--- a/src/version.c
+++ b/src/version.c
@@ -743,6 +743,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 1233,
+/**/
1232,
/**/
1231,