Re: Regex with > 32k different chars causes a backend crash

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема Re: Regex with > 32k different chars causes a backend crash
Дата
Msg-id 515DAFF9.2060505@vmware.com
обсуждение исходный текст
Ответ на Re: Regex with > 32k different chars causes a backend crash  (Noah Misch <noah@leadboat.com>)
Список pgsql-hackers
On 04.04.2013 03:32, Noah Misch wrote:
> On Wed, Apr 03, 2013 at 08:09:15PM +0300, Heikki Linnakangas wrote:
>> --- a/src/include/regex/regguts.h
>> +++ b/src/include/regex/regguts.h
>> @@ -148,6 +148,7 @@
>>   typedef short color;            /* colors of characters */
>>   typedef int pcolor;                /* what color promotes to */
>>
>> +#define MAX_COLOR    32767        /* max value that fits in 'color' datatype */
>
> This should use SHRT_MAX, no?  (Not that any supported platform differs here.)

I considered that, but I got all confused on whether limits.h needs to 
be included and where, if we use that. So I just used a constant 32767 
in the end. Committed that way.

I opened a ticket in TCL bug tracker for this: 
https://sourceforge.net/tracker/?func=detail&aid=3610026&group_id=10894&atid=110894. 


- Heikki



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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: psql crash fix
Следующее
От: Andrew Dunstan
Дата:
Сообщение: puzzling JSON bug