pgsql: Fix saving and restoring umask

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix saving and restoring umask
Date: 2017-09-22 21:17:32
Message-ID: E1dvVKG-0008Ux-Fb@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Fix saving and restoring umask

In two cases, we set a different umask for some piece of code and
restore it afterwards. But if the contained code errors out, the umask
is not restored. So add TRY/CATCH blocks to fix that.

Branch
------
master

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

Modified Files
--------------
src/backend/commands/copy.c | 11 ++++++++++-
src/backend/libpq/be-fsstubs.c | 13 +++++++++++--
2 files changed, 21 insertions(+), 3 deletions(-)

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2017-09-22 21:48:31 Re: pgsql: Fix saving and restoring umask
Previous Message Peter Eisentraut 2017-09-22 20:47:09 pgsql: Revert "Add basic TAP test setup for pg_upgrade"