From: Tom Lane Date: Sat, 7 Oct 2006 22:21:57 +0000 (+0000) Subject: Fix ancient oversight in psql's \d pattern processing code: when seeing two X-Git-Url: http://git.postgresql.org/gitweb/static/gitweb.js?a=commitdiff_plain;h=3251d1feff3a01b0c9788b3aaa95f9537289d0ba;p=users%2Fbernd%2Fpostgres.git Fix ancient oversight in psql's \d pattern processing code: when seeing two quote chars inside quote marks, should emit one quote *and stay in inquotes mode*. No doubt the lack of reports of this have something to do with the poor documentation of the feature ... --- diff --git a/src/bin/psql/describe.c b/src/bin/psql/describe.c index e36f924438..53d839c6d6 100644 --- a/src/bin/psql/describe.c +++ b/src/bin/psql/describe.c @@ -1673,7 +1673,8 @@ processNamePattern(PQExpBuffer buf, const char *pattern, appendPQExpBufferChar(&namebuf, '"'); cp++; } - inquotes = !inquotes; + else + inquotes = !inquotes; cp++; } else if (!inquotes && isupper((unsigned char) *cp))