Re: BUG #3841: core dump in uuid-ossp - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #3841: core dump in uuid-ossp
Date
Msg-id 19096.1198781471@sss.pgh.pa.us
Whole thread Raw
In response to Re: BUG #3841: core dump in uuid-ossp  (Alvaro Herrera <alvherre@commandprompt.com>)
Responses Re: BUG #3841: core dump in uuid-ossp  (Alvaro Herrera <alvherre@commandprompt.com>)
Re: BUG #3841: core dump in uuid-ossp  (Alvaro Herrera <alvherre@commandprompt.com>)
List pgsql-bugs
Alvaro Herrera <alvherre@commandprompt.com> writes:
>     if (err != NULL)
>         ereport(ERROR,
>                 (errmsg("OSSP uuid failure: %s", err)));
>     else
>         ereport(ERROR,
>                 (errmsg("OSSP uuid failure: error code %d", rc)));

Maybe "OSSP uuid library failure"?  Otherwise seems OK.

> Alternatively we could pass the called function name into
> pguuid_complain, but I'm not sure it's worth the trouble (what does it
> give the user, anyway?)

Probably not much, if the uuid_error() strings are well written.

Can we throw some more specific SQLSTATE than the default "internal
error" here?  Offhand I can't think of anything, but as a rule of
thumb an ereport() ought to have an errcode().  If it really is an
internal error then elog() is good enough.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: BUG #3841: core dump in uuid-ossp
Next
From: Alvaro Herrera
Date:
Subject: Re: BUG #3841: core dump in uuid-ossp