8000 Fix ecpg quoting bug in 6.5.* release. · rtpg/postgres@e539eb2 · GitHub
[go: up one dir, main page]

Skip to content

Commit e539eb2

Browse files
committed
Fix ecpg quoting bug in 6.5.* release.
1 parent ef26b94 commit e539eb2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/interfaces/ecpg/lib/ecpglib.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -365,7 +365,7 @@ next_insert(char *text)
365365
bool string = false;
366366

367367
for (; *ptr != '\0' && (*ptr != '?' || string); ptr++)
368-
if (*ptr == '\'')
368+
if (*ptr == '\'' && *(ptr-1) != '\\')
369369
string = string ? false : true;
370370

371371
return (*ptr == '\0') ? NULL : ptr;

0 commit comments

Comments
 (0)
0