From 281274572bcc3125fe6026a01ef7bf7ef584a0dd Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Mon, 13 May 2019 16:48:31 +0200 Subject: [PATCH] s3:smbspool: Print the filename we failed to open BUG: https://bugzilla.samba.org/show_bug.cgi?id=13939 Signed-off-by: Andreas Schneider Reviewed-by: Guenther Deschner --- source3/client/smbspool.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source3/client/smbspool.c b/source3/client/smbspool.c index efbdd418fdb..ef16c2bed42 100644 --- a/source3/client/smbspool.c +++ b/source3/client/smbspool.c @@ -224,7 +224,9 @@ main(int argc, /* I - Number of command-line arguments */ fp = fopen(print_file, "rb"); if (fp == NULL) { - perror("ERROR: Unable to open print file"); + fprintf(stderr, + "ERROR: Unable to open print file: %s", + print_file); goto done; }