postgres.git / summary / log / commit / refs
commit a52e6fe7bcf86f7e52d7b1d6f59260cb57b565fa
Author: Tom Lane <tgl@sss.pgh.pa.us>
Date: Sat Mar 31 15:19:23 2012 +0000
First released in: 9.2.0
Fix glitch recently introduced in psql tab completion.
Over-optimization (by me, looks like :-() broke the case of recognizing
a word boundary just before a quoted identifier. Reported and diagnosed
by Dean Rasheed.
src/bin/psql/tab-complete.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/bin/psql/tab-complete.c b/src/bin/psql/tab-complete.c
index 6f481bb24dd..975d65584b8 100644
--- a/src/bin/psql/tab-complete.c
+++ b/src/bin/psql/tab-complete.c
@@ -3595,7 +3595,7 @@ get_previous_words(int point, char **previous_words, int nwords)
{
if (buf[start] == '"')
inquotes = !inquotes;
- else if (!inquotes)
+ if (!inquotes)
{
if (buf[start] == ')')
parentheses++;
[parent: 5e83854d71bb]