Re: "unexpected EOF" messages - Mailing list pgsql-hackers

From Tom Lane
Subject Re: "unexpected EOF" messages
Date
Msg-id 8394.1336411720@sss.pgh.pa.us
Whole thread Raw
In response to Re: "unexpected EOF" messages  (Magnus Hagander <magnus@hagander.net>)
List pgsql-hackers
Magnus Hagander <magnus@hagander.net> writes:
> On Mon, May 7, 2012 at 7:18 PM, Robert Haas <robertmhaas@gmail.com> wrote:
>> Since the following hunk is repeated 3x, maybe it should be stuffed
>> into a function that is then called in three places:

> I considered it trivial enough not to do that for it. I can perhaps be
> convinced otherwise, but I doubt it's worth it..

I had considered suggesting the same, but decided not to on the grounds
that if we fold these into a subroutine, it will no longer be possible
to tell from the file-and-line-number info which call site reported the
error.  I'm not sure that there would be cases where we'd want to tell
that, but I'm not sure there wouldn't be, either.  So on the whole I
agree with the way Magnus coded it.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Uppercase tab completion keywords in psql?
Next
From: Boszormenyi Zoltan
Date:
Subject: Re: [PATCH] lock_timeout and common SIGALRM framework