pgsql: Fix calculation of space needed for parsed words in tab completi

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix calculation of space needed for parsed words in tab completi
Date: 2015-12-21 20:09:02
Message-ID: E1aB6lS-0006Tu-Ru@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Fix calculation of space needed for parsed words in tab completion.

Yesterday in commit d854118c8, I had a serious brain fade leading me to
underestimate the number of words that the tab-completion logic could
divide a line into. On input such as "(((((", each character will get
seen as a separate word, which means we do indeed sometimes need more
space for the words than for the original line. Fix that.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/f5a4370aea3580f5f7f59a77e41fde62f2be12d8

Modified Files
--------------
src/bin/psql/tab-complete.c | 60 +++++++++++++++++++++++--------------------
1 file changed, 32 insertions(+), 28 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Alvaro Herrera 2015-12-21 22:18:51 pgsql: adjust ACL owners for REASSIGN and ALTER OWNER TO
Previous Message Stephen Frost 2015-12-21 15:35:24 pgsql: Make viewquery a copy in rewriteTargetView()