diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2010-09-28 14:47:25 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2010-09-28 14:48:32 -0400 |
commit | e8b57bacacb8ddaaab3e832fc374c85b55f59b99 (patch) | |
tree | be91f8585e61de05744278ae38bd4373c8052021 /src | |
parent | dc9cc887b74bfa0d40829c4df66dead509fdd8f6 (diff) | |
download | postgresql-e8b57bacacb8ddaaab3e832fc374c85b55f59b99.tar.gz postgresql-e8b57bacacb8ddaaab3e832fc374c85b55f59b99.zip |
Fix another small oversight in command_no_begin patch.
Need a "return false" to prevent tests from continuing after we've moved
the "query" pointer. As it stood, it'd accept "DROP DISCARD ALL" as a
match.
Diffstat (limited to 'src')
-rw-r--r-- | src/bin/psql/common.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/bin/psql/common.c b/src/bin/psql/common.c index 81a633a3d01..76cba901e0c 100644 --- a/src/bin/psql/common.c +++ b/src/bin/psql/common.c @@ -1367,6 +1367,7 @@ command_no_begin(const char *query) return true; if (wordlen == 10 && pg_strncasecmp(query, "tablespace", 10) == 0) return true; + return false; } /* DISCARD ALL isn't allowed in xacts, but other variants are allowed. */ @@ -1382,6 +1383,7 @@ command_no_begin(const char *query) if (wordlen == 3 && pg_strncasecmp(query, "all", 3) == 0) return true; + return false; } return false; |