summaryrefslogtreecommitdiff
path: root/quote.c
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2008-06-01 21:34:49 -0700
committerH. Peter Anvin <hpa@zytor.com>2008-06-01 21:34:49 -0700
commit6ecc159a54c643a46c5682fd9245601c252924f5 (patch)
tree19ee83dab5cca46eb0840a6d1fcf92f7eaa907ac /quote.c
parent8cad14bbcf0b8c056e6f81dccf4af38537e0bac6 (diff)
downloadnasm-6ecc159a54c643a46c5682fd9245601c252924f5.tar.gz
nasm-6ecc159a54c643a46c5682fd9245601c252924f5.tar.bz2
nasm-6ecc159a54c643a46c5682fd9245601c252924f5.zip
qstring: backquoted strings seem to work now...
Hopefully backquoted strings should work correctly now.
Diffstat (limited to 'quote.c')
-rw-r--r--quote.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/quote.c b/quote.c
index 0d8ee2b..f926b85 100644
--- a/quote.c
+++ b/quote.c
@@ -340,6 +340,23 @@ size_t nasm_unquote(char *str)
break;
}
}
+ switch (state) {
+ case st_start:
+ case st_backslash:
+ break;
+ case st_oct:
+ *q++ = nval;
+ break;
+ case st_hex:
+ *q++ = ndig ? nval : *escp;
+ break;
+ case st_ucs:
+ if (ndig)
+ q = emit_utf8(q, nval);
+ else
+ *q++ = *escp;
+ break;
+ }
*q = '\0';
return q-str;
}