[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdebase/runtime/kioslave/trash
From:       David Faure <faure () kde ! org>
Date:       2009-12-01 0:04:11
Message-ID: 1259625851.818467.8753.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 1056840 by dfaure:

Remove the .info file when the actual trashed file doesn't exist anymore, rather than
giving an error message to the user. Hopefully with 4.4's interprocess lock such problems
can't happen anymore, but let's at least let people empty their trash no matter what.
Patch by David Engraf - thanks!
Fixed for: 4.4.0
BUG: 152194


 M  +1 -1      trashimpl.cpp  


--- trunk/KDE/kdebase/runtime/kioslave/trash/trashimpl.cpp #1056839:1056840
@@ -604,7 +604,7 @@
     for ( ; it != end ; ++it ) {
         const TrashedFileInfo& info = *it;
         const QString filesPath = info.physicalPath;
-        if ( synchronousDel( filesPath, true, true ) ) {
+        if ( synchronousDel( filesPath, true, true ) || m_lastErrorCode == KIO::ERR_DOES_NOT_EXIST) {
             QFile::remove( infoPath( info.trashId, info.fileId ) );
         } else {
             // error code is set by synchronousDel, let's remember it
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic