On Sat, Nov 27, 2010 at 11:23:46AM -0500, Tom Lane wrote:
> Magnus Hagander <mag...@hagander.net> writes:
> > Where does your uniqueidentifier.so file come from? It's not a part of
> > standard PostgreSQL 9.0, and this is the part that's crashing..
> 
> 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/

> > Any chance it's a third party module that you didn't recompile for 9.0?
> 
> 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:

PG_FUNCTION_INFO_V1(uniqueidentifier_out);
Datum
uniqueidentifier_out(PG_FUNCTION_ARGS)
{
    char *result;
    uniqueidentifier *in = (uniqueidentifier *) PG_GETARG_POINTER(0);

    if (in == NULL)
        PG_RETURN_CSTRING (NULL);

...and...

CREATE OR REPLACE FUNCTION uniqueidentifier_in(cstring)
    returns uniqueidentifier
    as 'MODULE_PATHNAME'
    language 'c';

It should use PG_ARGISNULL(0), no?

--
Joshua Tolley / eggyknap
End Point Corporation
http://www.endpoint.com

Attachment: signature.asc
Description: Digital signature

Reply via email to