pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Joshua Tolley <eggyknap@gmail.com>
Cc: Magnus Hagander <magnus@hagander.net>
Cc: Balamurugan Mahendran <balamurugan@adaptavant.com>
Cc: Craig Ringer <craig@postnewspapers.com.au>
Cc: pgsql-bugs@postgresql.org
Subject: Re: BUG #5773: DEBUG: reaping dead processes DEBUG: server process (PID 10007) was terminated by signal 11: Segme
Date: Sat, 27 Nov 2010 16:24:55 -0500
Message-ID: <1878.1290893095@sss.pgh.pa.us> (raw)
In-Reply-To: <4cf1742e.0f3dec0a.3014.ffffb065@mx.google.com>
References: <AANLkTin0Zy-_tRWSxA0sGqG3Kh91jQeXSgMJRgFCjxCk@mail.gmail.com>
	<4CF0CE91.3040101@postnewspapers.com.au>
	<AANLkTi=2VrTLZyja5D81rN3MwPYF7JPn84u5vEzEDLVu@mail.gmail.com>
	<4CF0E3BF.9010203@postnewspapers.com.au>
	<AANLkTimEGD70jpUBZWKzA+hnC0x4OsanPXby=hNeVFhE@mail.gmail.com>
	<4CF0E580.7030603@postnewspapers.com.au>
	<AANLkTi=3_TZwbfGXTkD3t2ZyG=ZQ+naCkYgYi2TkBUQJ@mail.gmail.com>
	<AANLkTimXAPNCAPY+zPtMuR8jRDDNc2KbfYWwfaM_F=y4@mail.gmail.com>
	<AANLkTim70ywBCGmJd83tvpXPB4M3p=ofpGvAQ=eemPUc@mail.gmail.com>
	<9739.1290875026@sss.pgh.pa.us>
	<4cf1742e.0f3dec0a.3014.ffffb065@mx.google.com>

Joshua Tolley <eggyknap@gmail.com> writes:
> On Sat, Nov 27, 2010 at 11:23:46AM -0500, Tom Lane wrote:
>> There used to be a project of that name on gborg.  I can't find the
>> source code anymore though.

> How about
> http://www.postgresql.org/ftp/projects/gborg/uniqueidentifier/stable/

Ah, thanks.

>> The magic-block mechanism should prevent that.  What I'm wondering about
>> is whether the input function is (a) careless about null input and (b)
>> not marked STRICT.

> I think you're right:

You're looking at the output function not the input function ... and
indeed the first thing the input function does is to invoke strlen(),
without any null check.

> It should use PG_ARGISNULL(0), no?

It'd be better to mark it STRICT in the SQL file (and likewise for the
output function).  Or actually what he *should* do is drop the whole
thing and use the now-built-in uuid type.

Now, this 2003-vintage tarball is obviously not what the OP is using,
since it hasn't even got a PG_MODULE_MAGIC call.  But if it hasn't
been updated any more than that, this'd explain a core dump on NULL
input.  What's a bit less clear is how the null got into the source
database without having triggered the same bug; but I suppose it
might've been generated via INSERT DEFAULT VALUES or some such.

			regards, tom lane



view thread (17+ messages)  latest in thread

Message-ID: <1878.1290893095@sss.pgh.pa.us>
Permalink:  ../1878.1290893095@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/1878.1290893095@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 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: tgl@sss.pgh.pa.us, eggyknap@gmail.com, magnus@hagander.net, balamurugan@adaptavant.com, craig@postnewspapers.com.au
  Subject: Re: BUG #5773: DEBUG: reaping dead processes DEBUG: server process (PID 10007) was terminated by signal 11: Segme
  In-Reply-To: <1878.1290893095@sss.pgh.pa.us>
  References: <AANLkTin0Zy-_tRWSxA0sGqG3Kh91jQeXSgMJRgFCjxCk@mail.gmail.com> <4CF0CE91.3040101@postnewspapers.com.au> <AANLkTi=2VrTLZyja5D81rN3MwPYF7JPn84u5vEzEDLVu@mail.gmail.com> <4CF0E3BF.9010203@postnewspapers.com.au> <AANLkTimEGD70jpUBZWKzA+hnC0x4OsanPXby=hNeVFhE@mail.gmail.com> <4CF0E580.7030603@postnewspapers.com.au> <AANLkTi=3_TZwbfGXTkD3t2ZyG=ZQ+naCkYgYi2TkBUQJ@mail.gmail.com> <AANLkTimXAPNCAPY+zPtMuR8jRDDNc2KbfYWwfaM_F=y4@mail.gmail.com> <AANLkTim70ywBCGmJd83tvpXPB4M3p=ofpGvAQ=eemPUc@mail.gmail.com> <9739.1290875026@sss.pgh.pa.us> <4cf1742e.0f3dec0a.3014.ffffb065@mx.google.com> <1878.1290893095@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