Use PQescapeString to ensure that tab-completion queries are not messed
authorTom Lane <tgl@sss.pgh.pa.us>
Tue, 14 Oct 2003 22:47:12 +0000 (22:47 +0000)
committerTom Lane <tgl@sss.pgh.pa.us>
Tue, 14 Oct 2003 22:47:12 +0000 (22:47 +0000)
commitbd398d0602c7a13e16af45ebe1171e7bc0ca16c2
tree17ed30f9b36911dbfef6892d7e5a02cbc557083c
parent6c48dd4d82afb12f99e531fc40d2ff0c603bf243
Use PQescapeString to ensure that tab-completion queries are not messed
up by quotes or backslashes in words that are being matched to database
names (per gripe from Ian Barwick, though I didn't use his patch).
Also fix possible memory leakage if _complete_with_query isn't run to
completion (not clear if that can happen or not, but be safe).
src/bin/psql/tab-complete.c