Re: BUG #14809: Heap Corruption with deeply nested triggers.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: matthew(dot)r(dot)maurer(at)gmail(dot)com
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #14809: Heap Corruption with deeply nested triggers.
Date: 2017-09-09 17:46:56
Message-ID: 5242.1504979216@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

matthew(dot)r(dot)maurer(at)gmail(dot)com writes:
> Log looks like: https://bpaste.net/show/4c1d3940ca27
> https://data.maurer.codes/clique.sql contains a reproduction case.

For the archives' sake, it'd have been better to include the test case.
The test isn't very large so I'll attach it below.

> On my machine, this consistently causes the glibc heap assertion in about 9
> seconds on a fresh database. If you get "ERROR: stack depth limit exceeded"
> you may need to increase your max_stack_depth to observe the error (mine was
> 2MB, but is a release build, debug builds might need more to hit this).

I tried a few different max_stack_depth settings on both 9.6 and HEAD,
but was unable to reproduce a crash. I see either a clean "stack depth
limit exceeded" failure, or successful completion of the query (at
stack depths above circa 3MB for me). Tested on RHEL6 x86_64; maybe
some other platform would show the problem.

regards, tom lane

Attachment Content-Type Size
clique.sql text/plain 3.0 KB

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Matthew Maurer 2017-09-09 17:58:44 Re: BUG #14809: Heap Corruption with deeply nested triggers.
Previous Message Tom Lane 2017-09-09 17:08:50 Re: BUG #14808: V10-beta4, backend abort