From: Marko Kreen Date: Sun, 12 Aug 2007 22:14:42 +0000 (+0000) Subject: wrap check order in quote_literal X-Git-Tag: pgbouncer_1_1~55 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2ec59ab19902ffa7210a75b395946224b04be36b;p=pgbouncer wrap check order in quote_literal --- diff --git a/src/varcache.c b/src/varcache.c index e8aeb07..7ba2175 100644 --- a/src/varcache.c +++ b/src/varcache.c @@ -82,7 +82,7 @@ static bool quote_literal(char *buf, int buflen, const char *src, bool std_quote while (*src && dst < end) { if (*src == '\'') *dst++ = '\''; - else if (!std_quote && *src == '\\') + else if (*src == '\\' && !std_quote) *dst++ = '\\'; *dst++ = *src++; }