From 61f8602e78ff81a2078b17bdb4fc1cc37c6ce63a Mon Sep 17 00:00:00 2001 From: ubbo Date: Fri, 14 May 2010 22:29:02 +0000 Subject: don't try to save file if abort is hit git-svn-id: http://cpunk.de/svn/src/gpg4usb/trunk@331 34ebc366-c3a9-4b3c-9f84-69acf7962910 --- attachments.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'attachments.cpp') diff --git a/attachments.cpp b/attachments.cpp index 4e62bd9..6cc03bd 100644 --- a/attachments.cpp +++ b/attachments.cpp @@ -98,6 +98,8 @@ void Attachments::saveByteArrayToFile(QByteArray outBuffer, QString filename) QString path=filename; QString outfileName = QFileDialog::getSaveFileName(this, tr("Save File"), path); + if(outfileName.isEmpty()) return; + QFile outfile(outfileName); if (!outfile.open(QFile::WriteOnly)) { QMessageBox::warning(this, tr("File"), -- cgit v1.2.3