PG Bug reporting form <noreply@postgresql.org> writes:
> Although libxml2 tries not to return a null message but both their xmlStrdup
> function and XML_GET_VAR_STR can return null in a OOM scenario.
Ugh.
> - appendStringInfoString(errorBuf, error->message);
> + if (error->message != NULL)
> + appendStringInfoString(errorBuf, error->message);
I'm inclined to do something more like
+ if (error->message != NULL)
+ appendStringInfoString(errorBuf, error->message);
+ else
+ appendStringInfoString(errorBuf, "(no message provided)");
else the output will read very oddly in this situation.
Thanks for the report!
regards, tom lane