Re: plpython crash on exception

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Marko Kreen" <markokr(at)gmail(dot)com>
Cc: "Alvaro Herrera" <alvherre(at)alvh(dot)no-ip(dot)org>, "Postgres Patches" <pgsql-patches(at)postgresql(dot)org>
Subject: Re: plpython crash on exception
Date: 2007-11-23 07:46:36
Message-ID: 24287.1195803996@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

"Marko Kreen" <markokr(at)gmail(dot)com> writes:
> On 11/23/07, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> Why? I can't imagine any real use for it. If you're thinking that
>> it could provide a guide as to what to resize the buffer to, think
>> again.

> If the output was truncated due to this limit then the return
> value is the number of characters (not including the trailing
> '\0') which would have been written to the final string if
> enough space had been available.

> What problem do you see?

The problem is that you are quoting from some particular system's
manual, and not any kind of standard ... much less any standard that
every platform we support follows.

The real-world situation is that we are lucky to be able to tell
vsnprintf success from failure at all :-(

regards, tom lane

In response to

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Marko Kreen 2007-11-23 08:53:50 Re: plpython crash on exception
Previous Message Marko Kreen 2007-11-23 07:28:43 Re: plpython crash on exception