1
0
mirror of https://github.com/postgres/postgres.git synced 2025-06-25 01:02:05 +03:00

Remove unnecessary escaping in C character literals

'\"' is more commonly written simply as '"'.
This commit is contained in:
Peter Eisentraut
2015-12-22 22:43:46 -05:00
parent 6efbded6e4
commit 30c0c4bf12
9 changed files with 22 additions and 22 deletions

View File

@ -197,7 +197,7 @@ output_escaped_str(char *str, bool quoted)
int i = 0;
int len = strlen(str);
if (quoted && str[0] == '\"' && str[len - 1] == '\"') /* do not escape quotes
if (quoted && str[0] == '"' && str[len - 1] == '"') /* do not escape quotes
* at beginning and end
* if quoted string */
{
@ -241,6 +241,6 @@ output_escaped_str(char *str, bool quoted)
fputc(str[i], yyout);
}
if (quoted && str[0] == '\"' && str[len] == '\"')
if (quoted && str[0] == '"' && str[len] == '"')
fputs("\"", yyout);
}