postgres.git / summary / log / commit / refs

commit    4009571695a28302da8bcc0b404238f26c19ad6f
Author:   Alvaro Herrera <alvherre@alvh.no-ip.org>
Date:     Fri May 08 23:38:46 2020 +0000
First released in: 13.0, 9.5.22, 9.6.18, 10.13, 11.8, 12.3

    pg_restore: Provide file name with one failure message
    
    Almost all error messages already include file name where relevant, but
    this one had been overlooked.  Repair.
    
    Backpatch to 9.5.
    
    Author: Euler Taveira <euler.taveira@2ndquadrant.com>
    Discussion: https://postgr.es/m/CAH503wA_VOrcKL_43p9atRejCDYmOZ8MzfK9S6TJrQqBqNeAXA@mail.gmail.com
    Reviewed-by: Álvaro Herrera <alvherre@alvh.no-ip.org>


src/bin/pg_dump/pg_backup_directory.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bin/pg_dump/pg_backup_directory.c b/src/bin/pg_dump/pg_backup_directory.c index 1a51b5cae12..7568bc1c0d3 100644 --- a/src/bin/pg_dump/pg_backup_directory.c +++ b/src/bin/pg_dump/pg_backup_directory.c @@ -411,8 +411,8 @@ _PrintFileData(ArchiveHandle *AH, char *filename) free(buf); if (cfclose(cfp) !=0) - exit_horribly(modulename, "could not close data file: %s\n", - strerror(errno)); + exit_horribly(modulename, "could not close data file \"%s\": %s\n", + filename, strerror(errno)); } /* [parent: 91d97462c96e]