pg.ddx.io pgsql-committers@postgresql.org mailing list archive
help / color / mirror / Atom feedpgsql: Fix pg_dump's errno checking for zlib I/O
6+ messages / 3 participants
[nested] [flat]
* pgsql: Fix pg_dump's errno checking for zlib I/O
@ 2017-08-02 22:28 Alvaro Herrera <alvherre@alvh.no-ip.org>
2017-08-03 02:09 ` Re: [COMMITTERS] pgsql: Fix pg_dump's errno checking for zlib I/O Alvaro Herrera <alvherre@2ndquadrant.com>
0 siblings, 1 reply; 6+ messages in thread
From: Alvaro Herrera @ 2017-08-02 22:28 UTC (permalink / raw)
To: pgsql-committers
Fix pg_dump's errno checking for zlib I/O
Some error reports were reporting strerror(errno), which for some error
conditions coming from zlib are wrong, resulting in confusing reports
such as
pg_restore: [compress_io] could not read from input file: Success
which makes no sense. To correctly extract the error message we need to
use gzerror(), so let's do that.
This isn't as comprehensive or as neat as I would like, but at least it
should improve things in many common cases. The zlib abstraction in
compress_io does not seem to be applied consistently enough; we could
perhaps improve that, but it seems master-only material, not a bug fix
for back-patching.
This problem goes back all the way, but I decided to apply back to 9.4
only, because older branches don't contain commit 14ea89366 which this
change depends on.
Authors: Vladimir Kunschikov, Álvaro Herrera
Discussion: https://postgr.es/m/1498120508308.9826@infotecs.ru
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/4d57e83816778c6f61ea35c697f937a6f9c3c3de
Modified Files
--------------
src/bin/pg_dump/compress_io.c | 24 +++++++++++++++++++++++-
src/bin/pg_dump/compress_io.h | 1 +
src/bin/pg_dump/pg_backup_directory.c | 10 +++++++---
src/bin/pg_dump/pg_backup_tar.c | 8 +++++++-
4 files changed, 38 insertions(+), 5 deletions(-)
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: [COMMITTERS] pgsql: Fix pg_dump's errno checking for zlib I/O
2017-08-02 22:28 pgsql: Fix pg_dump's errno checking for zlib I/O Alvaro Herrera <alvherre@alvh.no-ip.org>
@ 2017-08-03 02:09 ` Alvaro Herrera <alvherre@2ndquadrant.com>
2017-08-03 03:59 ` Re: [COMMITTERS] pgsql: Fix pg_dump's errno checking for zlib I/O Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 1 reply; 6+ messages in thread
From: Alvaro Herrera @ 2017-08-03 02:09 UTC (permalink / raw)
To: pgsql-hackers@postgresql.org
Alvaro Herrera wrote:
> Fix pg_dump's errno checking for zlib I/O
So this broke a few buildfarm members. I'll into it tomorrow.
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
^ permalink raw reply [nested|flat] 6+ messages in thread
* Re: [COMMITTERS] pgsql: Fix pg_dump's errno checking for zlib I/O
2017-08-02 22:28 pgsql: Fix pg_dump's errno checking for zlib I/O Alvaro Herrera <alvherre@alvh.no-ip.org>
2017-08-03 02:09 ` Re: [COMMITTERS] pgsql: Fix pg_dump's errno checking for zlib I/O Alvaro Herrera <alvherre@2ndquadrant.com>
@ 2017-08-03 03:59 ` Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 0 replies; 6+ messages in thread
From: Tom Lane @ 2017-08-03 03:59 UTC (permalink / raw)
To: Alvaro Herrera <alvherre@2ndquadrant.com>; +Cc: pgsql-hackers@postgresql.org
Alvaro Herrera <alvherre@2ndquadrant.com> writes:
> Alvaro Herrera wrote:
>> Fix pg_dump's errno checking for zlib I/O
> So this broke a few buildfarm members. I'll into it tomorrow.
I think you forgot to consider the !HAVE_LIBZ case.
regards, tom lane
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Fix pg_dump's errno checking for zlib I/O
@ 2017-08-02 22:28 Alvaro Herrera <alvherre@alvh.no-ip.org>
0 siblings, 0 replies; 6+ messages in thread
From: Alvaro Herrera @ 2017-08-02 22:28 UTC (permalink / raw)
To: pgsql-committers
Fix pg_dump's errno checking for zlib I/O
Some error reports were reporting strerror(errno), which for some error
conditions coming from zlib are wrong, resulting in confusing reports
such as
pg_restore: [compress_io] could not read from input file: Success
which makes no sense. To correctly extract the error message we need to
use gzerror(), so let's do that.
This isn't as comprehensive or as neat as I would like, but at least it
should improve things in many common cases. The zlib abstraction in
compress_io does not seem to be applied consistently enough; we could
perhaps improve that, but it seems master-only material, not a bug fix
for back-patching.
This problem goes back all the way, but I decided to apply back to 9.4
only, because older branches don't contain commit 14ea89366 which this
change depends on.
Authors: Vladimir Kunschikov, Álvaro Herrera
Discussion: https://postgr.es/m/1498120508308.9826@infotecs.ru
Branch
------
REL9_6_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/060393f2a13651bf53c7626a3587baaf82942023
Modified Files
--------------
src/bin/pg_dump/compress_io.c | 24 +++++++++++++++++++++++-
src/bin/pg_dump/compress_io.h | 1 +
src/bin/pg_dump/pg_backup_directory.c | 10 +++++++---
src/bin/pg_dump/pg_backup_tar.c | 8 +++++++-
4 files changed, 38 insertions(+), 5 deletions(-)
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Fix pg_dump's errno checking for zlib I/O
@ 2017-08-02 22:28 Alvaro Herrera <alvherre@alvh.no-ip.org>
0 siblings, 0 replies; 6+ messages in thread
From: Alvaro Herrera @ 2017-08-02 22:28 UTC (permalink / raw)
To: pgsql-committers
Fix pg_dump's errno checking for zlib I/O
Some error reports were reporting strerror(errno), which for some error
conditions coming from zlib are wrong, resulting in confusing reports
such as
pg_restore: [compress_io] could not read from input file: Success
which makes no sense. To correctly extract the error message we need to
use gzerror(), so let's do that.
This isn't as comprehensive or as neat as I would like, but at least it
should improve things in many common cases. The zlib abstraction in
compress_io does not seem to be applied consistently enough; we could
perhaps improve that, but it seems master-only material, not a bug fix
for back-patching.
This problem goes back all the way, but I decided to apply back to 9.4
only, because older branches don't contain commit 14ea89366 which this
change depends on.
Authors: Vladimir Kunschikov, Álvaro Herrera
Discussion: https://postgr.es/m/1498120508308.9826@infotecs.ru
Branch
------
REL9_5_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/f3142c027212967e0417ad3377563bbc8f314fce
Modified Files
--------------
src/bin/pg_dump/compress_io.c | 24 +++++++++++++++++++++++-
src/bin/pg_dump/compress_io.h | 1 +
src/bin/pg_dump/pg_backup_directory.c | 10 +++++++---
src/bin/pg_dump/pg_backup_tar.c | 8 +++++++-
4 files changed, 38 insertions(+), 5 deletions(-)
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
^ permalink raw reply [nested|flat] 6+ messages in thread
* pgsql: Fix pg_dump's errno checking for zlib I/O
@ 2017-08-02 22:28 Alvaro Herrera <alvherre@alvh.no-ip.org>
0 siblings, 0 replies; 6+ messages in thread
From: Alvaro Herrera @ 2017-08-02 22:28 UTC (permalink / raw)
To: pgsql-committers
Fix pg_dump's errno checking for zlib I/O
Some error reports were reporting strerror(errno), which for some error
conditions coming from zlib are wrong, resulting in confusing reports
such as
pg_restore: [compress_io] could not read from input file: Success
which makes no sense. To correctly extract the error message we need to
use gzerror(), so let's do that.
This isn't as comprehensive or as neat as I would like, but at least it
should improve things in many common cases. The zlib abstraction in
compress_io does not seem to be applied consistently enough; we could
perhaps improve that, but it seems master-only material, not a bug fix
for back-patching.
This problem goes back all the way, but I decided to apply back to 9.4
only, because older branches don't contain commit 14ea89366 which this
change depends on.
Authors: Vladimir Kunschikov, Álvaro Herrera
Discussion: https://postgr.es/m/1498120508308.9826@infotecs.ru
Branch
------
REL9_4_STABLE
Details
-------
https://git.postgresql.org/pg/commitdiff/330e68734b822416b5ef94da64f9b6b92f46c083
Modified Files
--------------
src/bin/pg_dump/compress_io.c | 24 +++++++++++++++++++++++-
src/bin/pg_dump/compress_io.h | 1 +
src/bin/pg_dump/pg_backup_directory.c | 10 +++++++---
src/bin/pg_dump/pg_backup_tar.c | 8 +++++++-
4 files changed, 38 insertions(+), 5 deletions(-)
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
^ permalink raw reply [nested|flat] 6+ messages in thread
end of thread, other threads:[~2017-08-03 03:59 UTC | newest]
Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2017-08-02 22:28 pgsql: Fix pg_dump's errno checking for zlib I/O Alvaro Herrera <alvherre@alvh.no-ip.org>
2017-08-03 02:09 ` Alvaro Herrera <alvherre@2ndquadrant.com>
2017-08-03 03:59 ` Tom Lane <tgl@sss.pgh.pa.us>
2017-08-02 22:28 pgsql: Fix pg_dump's errno checking for zlib I/O Alvaro Herrera <alvherre@alvh.no-ip.org>
2017-08-02 22:28 pgsql: Fix pg_dump's errno checking for zlib I/O Alvaro Herrera <alvherre@alvh.no-ip.org>
2017-08-02 22:28 pgsql: Fix pg_dump's errno checking for zlib I/O Alvaro Herrera <alvherre@alvh.no-ip.org>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox