diff options
author | Kevin McCarthy <kevin@8t8.us> | 2020-07-15 19:47:11 -0700 |
---|---|---|
committer | Kevin McCarthy <kevin@8t8.us> | 2020-07-19 13:43:08 -0700 |
commit | 62fab7bd4a6d143ed98a7fccc5bd37cfbcb012eb (patch) | |
tree | df750292cd7dc84c40172e0191e030a681030384 /init.c | |
parent | 9bb7acf736fd575b41560e8b837072299df4af0c (diff) |
Ensure a blackslash inside backquotes doesn't skip past eos.
I'm not sure if this is possible because of the way the input is read
by the muttrc parser, but fix the logic to ensure it can't happen.
Diffstat (limited to 'init.c')
-rw-r--r-- | init.c | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -236,7 +236,12 @@ int mutt_extract_token (BUFFER *dest, BUFFER *tok, int flags) { /* skip any quoted chars */ if (*pc == '\\') - pc += 2; + { + if (*(pc+1)) + pc += 2; + else + pc = NULL; + } } } while (pc && *pc != '`'); if (!pc) |