pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: luy70@psu.edu
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #18879: PostgreSQL returns memory error.
Date: Fri, 04 Apr 2025 17:32:13 -0400
Message-ID: <2047360.1743802333@sss.pgh.pa.us> (raw)
In-Reply-To: <18879-259fc59d072bd4d7@postgresql.org>
References: <18879-259fc59d072bd4d7@postgresql.org>

PG Bug reporting form <noreply@postgresql.org> writes:
> CREATE LOCAL TEMP TABLE IF NOT EXISTS v878825600 ( c878825601 INT
> COMPRESSION DEFAULT CONSTRAINT cons_878825602 REFERENCES v878825600 MATCH
> SIMPLE ON UPDATE NO ACTION ON DELETE SET DEFAULT ( c878825601, c878825601,
> c878825601, c878825601, c878825601, c878825601, c878825601 ) PRIMARY KEY )
> ON COMMIT DELETE ROWS;

Thanks for the report.  A less illegible repro is

regression=# create temp table v1 (c1 int primary key references v1 on delete set default (c1,c1));
WARNING:  problem in alloc set PortalContext: detected write past chunk end in block 0x2c25bc0, chunk 0x2c25e20
WARNING:  problem in alloc set PortalContext: detected write past chunk end in block 0x2c25bc0, chunk 0x2c25e20
CREATE TABLE

(With more repetitions of "c1" you can get a crash.)  It looks like
we're not being careful to reject duplicates in the SET DEFAULT list.

			regards, tom lane





view thread (2+ messages)

Message-ID: <2047360.1743802333@sss.pgh.pa.us>
Permalink:  ../2047360.1743802333@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/2047360.1743802333@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, luy70@psu.edu, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #18879: PostgreSQL returns memory error.
  In-Reply-To: <2047360.1743802333@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox