summaryrefslogtreecommitdiffstats
path: root/src/gui/painting/qcups.cpp
diff options
context:
space:
mode:
authorTrond Kjernåsen <trond@trolltech.com>2010-03-12 11:52:37 (GMT)
committerTrond Kjernåsen <trond@trolltech.com>2010-03-12 11:52:37 (GMT)
commit4f1b0d758e42872d2852e0eedd2417a858d603e2 (patch)
tree72a401f29b4b411fc072e2cbdc080cf2f66686aa /src/gui/painting/qcups.cpp
parent6e8c0095d0410a30ffa06bb0b0cb71f979becfb0 (diff)
downloadQt-4f1b0d758e42872d2852e0eedd2417a858d603e2.zip
Qt-4f1b0d758e42872d2852e0eedd2417a858d603e2.tar.gz
Qt-4f1b0d758e42872d2852e0eedd2417a858d603e2.tar.bz2
Removed a Valgrind warning.
Reviewed-by: Gunnar
Diffstat (limited to 'src/gui/painting/qcups.cpp')
-rw-r--r--src/gui/painting/qcups.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/gui/painting/qcups.cpp b/src/gui/painting/qcups.cpp
index ac41692..1ea1670 100644
--- a/src/gui/painting/qcups.cpp
+++ b/src/gui/painting/qcups.cpp
@@ -343,7 +343,8 @@ bool QCUPSSupport::printerHasPPD(const char *printerName)
if (!isAvailable())
return false;
const char *ppdFile = _cupsGetPPD(printerName);
- unlink(ppdFile);
+ if (ppdFile)
+ unlink(ppdFile);
return (ppdFile != 0);
}