Re: pgsql: Unite ReadBufferWithFork, ReadBufferWithStrategy, and

From: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
To: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: Simon Riggs <simon(at)2ndQuadrant(dot)com>, pgsql-committers(at)postgresql(dot)org
Subject: Re: pgsql: Unite ReadBufferWithFork, ReadBufferWithStrategy, and
Date: 2008-11-10 17:59:20
Message-ID: 49187678.4020209@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

Heikki Linnakangas wrote:
> Alvaro Herrera wrote:
>> Hmm. I see that some messages are now like this:
>>
>> (errmsg("unexpected data beyond EOF in block %u of relation %u/%u/%u/%u",
>> blockNum, smgr->smgr_rnode.spcNode, smgr->smgr_rnode.dbNode,
>> smgr->smgr_rnode.relNode, forkNum),
>>
>> but it seems that the file names contain symbolic fork names, not
>> numbers. Is it possible to build the error messages so that they report
>> the actual file name, or at least change the last /%u into a _%s with
>> the fork name?
>
> Agreed. There was some messages like that before, this patch just
> changed some error messages I had missed before. I'll change them all to
> match the file names ("%u/%u/%u_%s").

I guess I should just change those error messages to use relpath().
relpath() seems perfectly safe to call from those places; there's e.g.
no catalog access.

--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2008-11-10 18:02:21 pgsql: Fix bugs in sqlchar_to_unicode and unicode_to_sqlchar: both were
Previous Message Heikki Linnakangas 2008-11-10 17:36:53 pgsql: Fix 'Q' format char parsing in the new to_timestamp() code.

Browse pgsql-hackers by date

  From Date Subject
Next Message Joshua D. Drake 2008-11-10 18:16:34 Re: [WIP] In-place upgrade
Previous Message David E. Wheeler 2008-11-10 17:38:58 Re: gram.y=>preproc.y