Re: MemoryContextAlloc: invalid request size 1934906735

Поиск
Список
Период
Сортировка
От D'Arcy J.M. Cain
Тема Re: MemoryContextAlloc: invalid request size 1934906735
Дата
Msg-id 20020827113132.372641BBC@druid.net
обсуждение исходный текст
Ответ на Re: MemoryContextAlloc: invalid request size 1934906735  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: MemoryContextAlloc: invalid request size 1934906735
Список pgsql-hackers
On August 27, 2002 02:01 am, Tom Lane wrote:
> "D'Arcy J.M. Cain" <darcy@druid.net> writes:
> > I have been getting the subject message ever since upgrading to 7.2.1.  I
> > tried 7.2.2 with the same thing.  It seems to be related to my chkpass
> > type (see contrib) as it only happens on tables with that type.
>
> FWIW, I couldn't see any problem in CVS tip.  Could you provide an exact
> sequence-to-reproduce?

Surely.  Create a database (chkpass_test) and, after loading the chkpass 
type, follow this bouncing ball.

1. CREATE TABLE x (c chkpass);
2. INSERT INTO x VALUES ('a'); [Repeat 20 times]
3. VACUUM ANALYZE x;
4. UPDATE x SET c = ':a';
5. VACUUM ANALYZE x;
6. UPDATE x SET c = 'a';
7. VACUUM ANALYZE x;
8. GOTO 4

Note that 3 and 7 should fail most (95%?) of the time.  When it does, convert 
the invalid size to hex and compare the bytes of the integer with the 
encrypted value in the table.

Note that the fact that 5 does not fail has nothing to do with the path 
through chkpass.c.  If you take a failing password and insert it raw with 
"UPDATE x SET c = ':2w3dhratDt7xo';" then you get the same failure (even the 
same number - 1952543340 in my case) as you did when chkpass encrypted with 
that salt.

-- 
D'Arcy J.M. Cain <darcy@{druid|vex}.net>   |  Democracy is three wolves
http://www.druid.net/darcy/                |  and a sheep voting on
+1 416 425 1212     (DoD#0082)    (eNTP)   |  what's for dinner.


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

Предыдущее
От: "Zeugswetter Andreas SB SD"
Дата:
Сообщение: Re: Default privileges for new databases (was Re: Can't
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Think I see a btree vacuuming bug