Handle some corner cases around empty strings in SET commands.
authorPavan Deolasee <pavan.deolasee@gmail.com>
Tue, 31 Jan 2017 17:29:10 +0000 (22:59 +0530)
committerPavan Deolasee <pavan.deolasee@gmail.com>
Tue, 31 Jan 2017 17:29:10 +0000 (22:59 +0530)
commit9540e4adebb1468b6b3862507feac47a2c6f5cb5
tree465484320b620382c80a3ec908ede981b8915fdf
parent1b6ada225da45c82529d56f71e3c6a62fabcfd55
Handle some corner cases around empty strings in SET commands.

There are some tricky situations where a SET command may only use an empty
string ('') as a value. This lead to various problems since the value is
converted into an zero length string or even a \"\" by GUC processor, depending
on whether it appears in a quoted list GUC or a normal GUC. Sending the value
to the remote node on any of these formats is guaranteed to break things. So
for now add some band-aids to deal with these special cases.

Per report from Vivek Shukla (vivek.shukla@evidentit.co.uk)
src/backend/utils/misc/guc.c
src/include/utils/guc.h