diff options
author | Josh Rahm <joshuarahm@gmail.com> | 2023-01-25 18:31:55 +0000 |
---|---|---|
committer | Josh Rahm <joshuarahm@gmail.com> | 2023-01-25 18:31:55 +0000 |
commit | 067dc73729267c0262438a6fdd66e586f8496946 (patch) | |
tree | d2e832f1a08083fd1457aaba9a774e72d69e5266 /src/mpack/mpack_core.c | |
parent | cd16d3df4c2a21ada895a1353712969045e5c728 (diff) | |
parent | 3c48d3c83fc21dbc0841f9210f04bdb073d73cd1 (diff) | |
download | rneovim-067dc73729267c0262438a6fdd66e586f8496946.tar.gz rneovim-067dc73729267c0262438a6fdd66e586f8496946.tar.bz2 rneovim-067dc73729267c0262438a6fdd66e586f8496946.zip |
Merge remote-tracking branch 'upstream/master' into fix_repeatcmdline
Diffstat (limited to 'src/mpack/mpack_core.c')
-rw-r--r-- | src/mpack/mpack_core.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mpack/mpack_core.c b/src/mpack/mpack_core.c index 4ee67a032a..3424f444b9 100644 --- a/src/mpack/mpack_core.c +++ b/src/mpack/mpack_core.c @@ -173,6 +173,9 @@ MPACK_API int mpack_write(mpack_tokbuf_t *tokbuf, char **buf, size_t *buflen, int mpack_rtoken(const char **buf, size_t *buflen, mpack_token_t *tok) { + if (*buflen == 0) { + return MPACK_EOF; + } unsigned char t = ADVANCE(buf, buflen); if (t < 0x80) { /* positive fixint */ |