(literalchar): fixed the code for escaping double quotes (thanks

Jonathan Czisny.)
This commit is contained in:
Jesse Thilo
1999-04-18 15:17:30 +00:00
parent f9b730cd59
commit e5335b7401

View File

@@ -271,7 +271,9 @@ literalchar (char **pp, int *pcode, char term)
so that `\012' and `\n' can be interchangeable. */
p = *pp;
if (code == '\\') {*p++ = '\\'; *p++ = '\\';}
if (code == term && wasquote)
*p++ = code;
else if (code == '\\') {*p++ = '\\'; *p++ = '\\';}
else if (code == '\'') {*p++ = '\\'; *p++ = '\'';}
else if (code == '\"') {*p++ = '\\'; *p++ = '\"';}
else if (code >= 040 && code < 0177)