From 94e83e385e5ba66f1415164214f7afd5e4ad7536 Mon Sep 17 00:00:00 2001 From: =?utf8?q?G=C3=BCnther=20Deschner?= Date: Wed, 22 Dec 2010 11:34:22 +0100 Subject: [PATCH] s3-printing: fix crash bug in print_spool_open(). MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Guenther Autobuild-User: Günther Deschner Autobuild-Date: Wed Dec 22 14:21:58 CET 2010 on sn-devel-104 --- source3/printing/printspoolss.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source3/printing/printspoolss.c b/source3/printing/printspoolss.c index 8426b84fec5..8effb6ec482 100644 --- a/source3/printing/printspoolss.c +++ b/source3/printing/printspoolss.c @@ -208,7 +208,9 @@ done: if (!NT_STATUS_IS_OK(status)) { if (fd != -1) { close(fd); - unlink(fsp->print_file->filename); + if (fsp->print_file) { + unlink(fsp->print_file->filename); + } } /* We need to delete the job from spoolss too */ if (pf->jobid) { -- 2.11.4.GIT