From d51b6688a7132d6f5d355aae5ccb7aa7fdab4b74 Mon Sep 17 00:00:00 2001 From: tpearson Date: Thu, 25 Mar 2010 18:47:46 +0000 Subject: [PATCH] Should fix empty temp files being left around git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1107469 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kopete/protocols/msn/incomingtransfer.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/kopete/protocols/msn/incomingtransfer.cpp b/kopete/protocols/msn/incomingtransfer.cpp index 99422ef7..d6a89f38 100644 --- a/kopete/protocols/msn/incomingtransfer.cpp +++ b/kopete/protocols/msn/incomingtransfer.cpp @@ -177,6 +177,9 @@ void IncomingTransfer::processMessage(const Message& message) else if(message.header.dataSize == 4 && message.applicationIdentifier == 1) { // Data preparation message. + if (m_tempFile.name.isEmpty() == false) { + QFile::remove(m_tempFile.name()); + } m_tempFile = new KTempFile(locateLocal("tmp", "msnpicture--"), ".png"); m_tempFile->setAutoDelete(true); m_file = m_tempFile->file();