Re: The return value of allocate_recordbuf()
От | Andres Freund |
---|---|
Тема | Re: The return value of allocate_recordbuf() |
Дата | |
Msg-id | 20150108123910.GC12509@alap3.anarazel.de обсуждение исходный текст |
Ответ на | Re: The return value of allocate_recordbuf() (Michael Paquier <michael.paquier@gmail.com>) |
Список | pgsql-hackers |
Hi, On 2015-01-05 14:18:35 +0900, Michael Paquier wrote: > Note that for 9.4, I think that we should complain about an OOM in > logical.c where malloc is used as now process would simply crash if > NULL is returned by XLogReaderAllocate. That's the object of the > second patch. Yes, that's clearly an oversight... > ctx->reader = XLogReaderAllocate(read_page, ctx); > + if (!ctx->reader) > + ereport(ERROR, > + (errcode(ERRCODE_OUT_OF_MEMORY), > + errmsg("out of memory"), > + errdetail("Failed while allocating an XLog reading processor."))); > + I've removed the errdetail() as a) its content is quite confusing b) we don't add error details that don't add more information than the function name already does as it's implicitly included in the logging. Greetings, Andres Freund -- Andres Freund http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training & Services
В списке pgsql-hackers по дате отправления: