DSA_ALLOC_NO_OOM doesn't work - Mailing list pgsql-bugs

From Heikki Linnakangas
Subject DSA_ALLOC_NO_OOM doesn't work
Date
Msg-id 5efa4a5e-2b8b-42dd-80ed-f920718cf5c0@iki.fi
Whole thread Raw
List pgsql-bugs
If you call dsa_allocate_extended(DSA_ALLOC_NO_OOM), it will still 
ereport an error if you run out of space (originally reported at [0]).

Attached patch adds code to test_dsa.c to demonstrate that:

postgres=# select test_dsa_basic();
ERROR:  could not resize shared memory segment "/PostgreSQL.1312700148" 
to 1075843072 bytes: No space left on device

[0] https://github.com/pgvector/pgvector/issues/434#issuecomment-1912744489

-- 
Heikki Linnakangas
Neon (https://neon.tech)
Attachment

pgsql-bugs by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: MarkBufferDirty Assert held LW_EXCLUSIVE lock fail when ginFinishSplit
Next
From: Tender Wang
Date:
Subject: Re: BUG #18314: PARALLEL UNSAFE function does not prevent parallel index build