]> SALOME platform Git repositories - modules/hydro.git/commitdiff
Salome HOME
refs #601: avoid using working directory as a temp directory.
authormzn <mzn@opencascade.com>
Wed, 24 Jun 2015 06:33:15 +0000 (09:33 +0300)
committermzn <mzn@opencascade.com>
Wed, 24 Jun 2015 06:33:15 +0000 (09:33 +0300)
src/HYDROGUI/HYDROGUI_RecognizeContoursOp.cxx

index 5b948492903d2dc07586918d1808e1d4461c25db..9eb098fed541c823c562d616f07f6189ff9ddcc2 100644 (file)
@@ -53,6 +53,7 @@
 #include <gp_GTrsf.hxx>
 
 #include <QDialog>
+#include <QDir>
 #include <QTemporaryFile>
 
 /**
@@ -99,7 +100,7 @@ void HYDROGUI_RecognizeContoursOp::startOperation()
 
   // Create temporary graphics file
   QImage aQImage = myImage->Image();
-  myTmpImageFile = new QTemporaryFile( anImageName );
+  myTmpImageFile = new QTemporaryFile( QDir::tempPath() + QDir::separator() + anImageName );
   if ( !myTmpImageFile->open() || 
        !aQImage.save( myTmpImageFile->fileName(), "PNG", 100 ) ) {
     abort();