diff options
author | Bram Moolenaar <Bram@vim.org> | 2018-04-05 22:44:39 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2018-04-05 22:44:39 +0200 |
commit | d5359b24ceefefed4b3a37efd9bf54176935f3a5 (patch) | |
tree | 254e2c8d143161dc57e86003127da51f99f644b9 /src/evalfunc.c | |
parent | 9a993e3c09371bb80d71be62fca53cf954a98f72 (diff) | |
download | vim-git-d5359b24ceefefed4b3a37efd9bf54176935f3a5.tar.gz |
patch 8.0.1666: % argument in ch_log() causes troublev8.0.1666
Problem: % argument in ch_log() causes trouble.
Solution: Use string as third argument in internal ch_log(). (Dominique
Pelle, closes #2784)
Diffstat (limited to 'src/evalfunc.c')
-rw-r--r-- | src/evalfunc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/evalfunc.c b/src/evalfunc.c index dc2c14c3d..1ffbb21fa 100644 --- a/src/evalfunc.c +++ b/src/evalfunc.c @@ -1993,7 +1993,7 @@ f_ch_log(typval_T *argvars, typval_T *rettv UNUSED) if (argvars[1].v_type != VAR_UNKNOWN) channel = get_channel_arg(&argvars[1], FALSE, FALSE, 0); - ch_log(channel, (char *)msg); + ch_log(channel, "%s", msg); } /* @@ -12927,7 +12927,7 @@ get_callback(typval_T *arg, partial_T **pp) } /* - * Unref/free "callback" and "partial" retured by get_callback(). + * Unref/free "callback" and "partial" returned by get_callback(). */ void free_callback(char_u *callback, partial_T *partial) |