QtPrintSupport: cleanup CUPS tmp files
authorTeemu Katajisto <teemu.katajisto@digia.com>
Tue, 25 Sep 2012 11:15:07 +0000 (14:15 +0300)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Thu, 27 Sep 2012 04:07:20 +0000 (06:07 +0200)
Set fd so that it gets closed in QPdfPrintEnginePrivate::closePrintDevice()

Task-number: QTBUG-14724

Change-Id: Ic9c02c92b07ece92911d7bc3eac79689b4864253
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
src/plugins/printsupport/cups/qcupsprintengine.cpp

index 82735ee..6a0e9a8 100644 (file)
@@ -180,6 +180,7 @@ bool QCupsPrintEnginePrivate::openPrintDevice()
         cupsTempFile = ret.second;
         outDevice = new QFile();
         static_cast<QFile *>(outDevice)->open(ret.first, QIODevice::WriteOnly);
+        fd = ret.first;
     }
 
     return true;