Re: Error during hash index scans can cause postgres halt!

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Error during hash index scans can cause postgres halt!
Дата
Msg-id 16136.1204906397@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Error during hash index scans can cause postgres halt!  ("Heikki Linnakangas" <heikki@enterprisedb.com>)
Список pgsql-bugs
"Heikki Linnakangas" <heikki@enterprisedb.com> writes:
> Tom Lane wrote:
>> Ouch.  So this has been broken (by me, I think :-() since 8.0.  Tells
>> you something about how many people use hash indexes :-(

> Yeah. Also, this is very hard to trigger without --enable-cassert (or
> just CLOBBER_FREED_MEMORY). It's extremely unlikely that something new
> is allocated on the piece of memory that was used by an HashScanList
> item, during AbortTransaction processing.

> ykhuang, were you running an assertion-enabled build as well?

The pfree() would touch the context control data, not just the
HashScanList struct itself.  Also on some platforms it's possible that
malloc would've returned the freed context to the system, resulting in
a segfault because we touch unmapped memory.  But I agree that it'd
be far more probable to see the problem with --enable-cassert.

> Want me to hack up a patch, or you going to just commit that yourself?

Already done, I didn't see your message till just now.

            regards, tom lane

В списке pgsql-bugs по дате отправления:

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Error during hash index scans can cause postgres halt!
Следующее
От: Stephan Szabo
Дата:
Сообщение: Re: BUG #4019: Comparison of user defined domain doesn't work