pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: exclusion@gmail.com
To: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #16801: Invalid memory access on WITH RECURSIVE with nested WITHs
Date: Sun, 3 Jan 2021 14:15:58 +0900
Message-ID: <X/FTDocQD3D7+aIJ@paquier.xyz> (raw)
In-Reply-To: <16801-393c7922143eaa4d@postgresql.org>
References: <16801-393c7922143eaa4d@postgresql.org>

On Sat, Jan 02, 2021 at 03:00:00PM +0000, PG Bug reporting form wrote:
> valgrind detects an invalid read:
> ==00:00:00:04.145 217144== Invalid read of size 8
> ==00:00:00:04.145 217144==    at 0x302CB7: makeDependencyGraphWalker
> (parse_cte.c:549)
> ==00:00:00:04.145 217144==    by 0x302EA1: makeDependencyGraph
> (parse_cte.c:439)
> ==00:00:00:04.145 217144==    by 0x304557: transformWithClause
> (parse_cte.c:176)
>
> The first bad commit is 1cff1b95.

The same kind of list manipulation is done in two places in
parse_cte.c, and there are extra ones in split_pathtarget_walker().  I
cannot reproduce that here, and I have just tried with different
optimization levels on HEAD and REL_13_STABLE.  Are you using specific
options for valgrind?
--
Michael

Attachments:

  signature.asc (application/pgp-signature, 832B) download

view thread (18+ messages)  latest in thread

Message-ID: <X/FTDocQD3D7+aIJ@paquier.xyz>
Permalink:  ../X%2FFTDocQD3D7+aIJ@paquier.xyz/
Also on:    postgresql.org/message-id/X/FTDocQD3D7+aIJ@paquier.xyz

 · 

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-bugs@postgresql.org
  Cc: michael@paquier.xyz, exclusion@gmail.com
  Subject: Re: BUG #16801: Invalid memory access on WITH RECURSIVE with nested WITHs
  In-Reply-To: <X/FTDocQD3D7+aIJ@paquier.xyz>
  References: <16801-393c7922143eaa4d@postgresql.org> <X/FTDocQD3D7+aIJ@paquier.xyz>

* 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