"Robin Haberkorn" <haberk...@b1-systems.de> writes: > I forgot the patch of course...
Hi Robin, thank you for the patch! This has arrived too late to be considered for PG v18, but please add the thread to the open commitfest https://commitfest.postgresql.org/53/ so that we don't forget about it for v19, and so that it will receive automated testing from our cfbot. Just from a quick eyeballing of the patch, it seems generally sane, but I wonder why you have xml_generic_error_handler creating and then destroying an errorBuf instead of just appending the results directly to xmlerrcxt->err_buf. The extra buffer doesn't seem to be doing much except increasing our odds of an OOM failure right there. I'm also a little suspicious of - xmlerrcxt = pgxml_parser_init(PG_XML_STRICTNESS_LEGACY); + xmlerrcxt = pgxml_parser_init(PG_XML_STRICTNESS_ALL); as that looks like it is probably changing the behavior of the module in ways bigger than just providing more error details. This code has been in legacy status for so long that I feel a little hesitant about doing that. If we are willing to do it, should we go further and clean out the use of PG_XML_STRICTNESS_LEGACY in xml2/xpath.c as well? regards, tom lane