pgsql: Fix case of pg_dump -Fc to an unseekable file (such as a pipe).

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix case of pg_dump -Fc to an unseekable file (such as a pipe).
Date: 2014-05-05 15:26:51
Message-ID: E1WhKn5-0002DM-6P@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Fix case of pg_dump -Fc to an unseekable file (such as a pipe).

This was accidentally broken in commits cfa1b4a711/5e8e794e3b.
It saves a line or so to call ftello unconditionally in _CloseArchive,
but we have to expect that it might fail if we're not in hasSeek mode.
Per report from Bernd Helmle.

In passing, improve _getFilePos to print an appropriate message if
ftello fails unexpectedly, rather than just a vague complaint about
"ftell mismatch".

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/e03485ae8a2025d5deea291ebb24412229cc2fe5

Modified Files
--------------
src/bin/pg_dump/pg_backup_custom.c | 22 +++++++++++++---------
1 file changed, 13 insertions(+), 9 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Andres Freund 2014-05-05 15:58:35 Re: pgsql: Revive line type
Previous Message Tom Lane 2014-05-05 14:54:57 Re: pgsql: Minor pg_dump improvements