"Albe Laurenz" <laurenz.albe@wien.gv.at> writes:
> I have attached a new version of the patch that should address all known
> problems.
You missed one "return" where the string needed to be freed. I've
applied this patch with that fix and a couple of cosmetic changes.
Thanks for the report and patch!
regards, tom lane