pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: kyzevan23@mail.ru
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #17561: Server crashes on executing row() with very long argument list
Date: Fri, 29 Jul 2022 09:55:53 -0400
Message-ID: <3753050.1659102953@sss.pgh.pa.us> (raw)
In-Reply-To: <20220729101411.7b45rvhlrsgcajjo@alvherre.pgsql>
References: <20220729101411.7b45rvhlrsgcajjo@alvherre.pgsql>

Alvaro Herrera <alvherre@alvh.no-ip.org> writes:
> On 2022-Jul-29, PG Bug reporting form wrote:
>> When executing the following query:
>> (echo "SELECT row("; for ((i=1;i<100001;i++)); do echo "'$i',$i,"; done;
>> echo "'0',0);"; ) | psql
>> I got server crash with the following backtrace

> Hah, of course.  I suppose we'd need something like this ... haven't
> looked for other problem spots.

I think the parser should've prevented this.  It's in charge of
rejecting overlength SELECT lists, for example.  Also, the limit
probably needs to be just MaxTupleAttributeNumber.

			regards, tom lane





view thread (9+ messages)  latest in thread

Message-ID: <3753050.1659102953@sss.pgh.pa.us>
Permalink:  ../3753050.1659102953@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/3753050.1659102953@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, alvherre@alvh.no-ip.org, kyzevan23@mail.ru, pgsql-bugs@lists.postgresql.org
  Subject: Re: BUG #17561: Server crashes on executing row() with very long argument list
  In-Reply-To: <3753050.1659102953@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