mirror of
https://github.com/postgres/postgres.git
synced 2025-06-27 23:21:58 +03:00
Remove unnecessary escaping in C character literals
'\"' is more commonly written simply as '"'.
This commit is contained in:
@ -3007,16 +3007,16 @@ SplitIdentifierString(char *rawstring, char separator,
|
||||
char *curname;
|
||||
char *endp;
|
||||
|
||||
if (*nextp == '\"')
|
||||
if (*nextp == '"')
|
||||
{
|
||||
/* Quoted name --- collapse quote-quote pairs, no downcasing */
|
||||
curname = nextp + 1;
|
||||
for (;;)
|
||||
{
|
||||
endp = strchr(nextp + 1, '\"');
|
||||
endp = strchr(nextp + 1, '"');
|
||||
if (endp == NULL)
|
||||
return false; /* mismatched quotes */
|
||||
if (endp[1] != '\"')
|
||||
if (endp[1] != '"')
|
||||
break; /* found end of quoted name */
|
||||
/* Collapse adjacent quotes into one quote, and look again */
|
||||
memmove(endp, endp + 1, strlen(endp));
|
||||
@ -3132,16 +3132,16 @@ SplitDirectoriesString(char *rawstring, char separator,
|
||||
char *curname;
|
||||
char *endp;
|
||||
|
||||
if (*nextp == '\"')
|
||||
if (*nextp == '"')
|
||||
{
|
||||
/* Quoted name --- collapse quote-quote pairs */
|
||||
curname = nextp + 1;
|
||||
for (;;)
|
||||
{
|
||||
endp = strchr(nextp + 1, '\"');
|
||||
endp = strchr(nextp + 1, '"');
|
||||
if (endp == NULL)
|
||||
return false; /* mismatched quotes */
|
||||
if (endp[1] != '\"')
|
||||
if (endp[1] != '"')
|
||||
break; /* found end of quoted name */
|
||||
/* Collapse adjacent quotes into one quote, and look again */
|
||||
memmove(endp, endp + 1, strlen(endp));
|
||||
|
Reference in New Issue
Block a user