Kmail: check fcc collection in the MDA.
Review Request #100829 - Created March 9, 2011 and submitted
Hello This patch is fixing a hole in the MDA. If the fcc folder is deleted when the message is queued, then the mail is lost. With my patch the mail is saving in the default sent-mail collection. I forgot to check for the whitespace... So i update my diff. Sorry for the trouble.
Kdepim-runtime and kdepim is compiling without any issue.
Review request changed
moveTo is unused now. In fact the whole structure of the code now doesn't make sense anymore. For example, when the sentBehaviour attribute has a behaviour of MoveToDefaultCollection, the mail is not moved at all anymore! To correct this, you should probably still start an ItemMoveJob in line 279, with the default collection. Also, in line 277, the job should be aborted with an error. Both of these things were done in the code a bit below that was removed. After that, the moveTo variable can be removed.
Thanks for the patch, I have just comitted it, see http://commits.kde.org/kdepim-runtime/a074f5ed435de191abd420230f04912e8dca75f6. I have changed a few things before comotting: - Correctly assign mCurrentJob so that the parent job can correctly be aborted - Set the job to an error state when hasDefaultCollection() return false - also check for hasDefaultCollection() in the result slot - added a few more uses of the "const" keyword