pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Ensure write failure reports no-disk-space
Date: Fri, 19 Jun 2020 21:26:58 +0000
Message-ID: <E1jmOXK-0008SQ-MV@gemulon.postgresql.org> (raw)

Ensure write failure reports no-disk-space

A few places calling fwrite and gzwrite were not setting errno to ENOSPC
when reporting errors, as is customary; this led to some failures being
reported as
"could not write file: Success"
which makes us look silly.  Make a few of these places in pg_dump and
pg_basebackup use our customary pattern.

Backpatch-to: 9.5
Author: Justin Pryzby <pryzby@telsasoft.com>
Author: Tom Lane <tgl@sss.pgh.pa.us>
Author: Álvaro Herrera <alvherre@alvh.no-ip.org>
Discussion: https://postgr.es/m/20200611153753.GU14879@telsasoft.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/ae3259c55067c926d25c745d70265fca15c2d26b

Modified Files
--------------
src/bin/pg_basebackup/pg_basebackup.c | 16 ++++++++++++++++
src/bin/pg_dump/pg_backup_directory.c | 18 ++++++++++++++++++
2 files changed, 34 insertions(+)



view thread (7+ messages)  latest in thread

Message-ID: <E1jmOXK-0008SQ-MV@gemulon.postgresql.org>
Permalink:  ../E1jmOXK-0008SQ-MV@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1jmOXK-0008SQ-MV@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: alvherre@alvh.no-ip.org
  Subject: Re: pgsql: Ensure write failure reports no-disk-space
  In-Reply-To: <E1jmOXK-0008SQ-MV@gemulon.postgresql.org>
  References: <E1jmOXK-0008SQ-MV@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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