commit | 80e78847395b5c8ada7861674774d81bd0a42789 | [log] [tgz] |
---|---|---|
author | Bram Moolenaar <Bram@vim.org> | Sun Feb 28 15:21:13 2016 +0100 |
committer | Bram Moolenaar <Bram@vim.org> | Sun Feb 28 15:21:13 2016 +0100 |
tree | d888b4d1ed9fac19257d81972b2e60286a662d4c | |
parent | b36287283781e09d8874157b9d9bdc5243a2f319 [diff] [blame] |
patch 7.4.1446 Problem: Crash when using json_decode(). Solution: Terminate string with a NUL byte.
diff --git a/src/json.c b/src/json.c index d501928..cf887e5 100644 --- a/src/json.c +++ b/src/json.c
@@ -659,6 +659,7 @@ ++reader->js_used; if (res != NULL) { + ga_append(&ga, NUL); res->v_type = VAR_STRING; #if defined(FEAT_MBYTE) && defined(USE_ICONV) if (!enc_utf8)