diff options
author | Cyrill Gorcunov <gorcunov@gmail.com> | 2014-11-23 18:26:54 +0300 |
---|---|---|
committer | Cyrill Gorcunov <gorcunov@gmail.com> | 2014-11-23 18:26:54 +0300 |
commit | a45febd767642dafc017a3210f357c7a2139e475 (patch) | |
tree | 9dff28fb31b5927108307a7ec1c093238fbb3b07 | |
parent | 5c0b082c9289d78577168ad7eaf13b56c58deb5c (diff) | |
download | nasm-a45febd767642dafc017a3210f357c7a2139e475.tar.gz |
quote: Fix returning out of string pointer
In case if string is a single grave accent we
return the pointer to uninitialized space.
http://bugzilla.nasm.us/show_bug.cgi?id=3392292
Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
-rw-r--r-- | quote.c | 4 |
1 files changed, 3 insertions, 1 deletions
@@ -441,8 +441,10 @@ char *nasm_skip_string(char *str) return p; } else if (bq == '`') { /* `...` string */ - p = str+1; state = st_start; + p = str+1; + if (!*p) + return p; while ((c = *p++)) { switch (state) { |