Re: pg_dump's checkSeek() seems inadequate

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: pg_dump's checkSeek() seems inadequate
Date: 2010-06-28 00:55:52
Message-ID: 4908.1277686552@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> On Sun, Jun 27, 2010 at 6:19 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> A somewhat more plausible scenario is that somebody might hope that
>> they could do something like this:
>>
>> echo 'some custom header' >pg.dump
>> pg_dump -Fc >>pg.dump

> That doesn't actually sound all that far-fetched.

I've got my doubts, but I guess we could write an even-more-bulletproof
test by doing ftello() and then seeing if fseeko to that position
complains. This might be a good thing anyway since most of the other
uses of ftello aren't really checking for errors ...

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2010-06-28 01:02:58 Re: suppress automatic recovery after back crash
Previous Message Robert Haas 2010-06-28 00:54:40 suppress automatic recovery after back crash