Re: BUG #15624: Sefgault when xml_errorHandler receives a null error->message from libxml2
В списке pgsql-bugs по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: BUG #15624: Sefgault when xml_errorHandler receives a null error->message from libxml2 |
| Дата | |
| Msg-id | 32330.1549648428@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | BUG #15624: Sefgault when xml_errorHandler receives a null error->message from libxml2 (PG Bug reporting form <noreply@postgresql.org>) |
| Ответы |
Re: BUG #15624: Sefgault when xml_errorHandler receives a nullerror->message from libxml2
|
| Список | pgsql-bugs |
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
В списке pgsql-bugs по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера