Summary: | [PATCH] MDN not asked on deleting mail | ||
---|---|---|---|
Product: | [Unmaintained] kmail | Reporter: | Frank Niethardt <frank> |
Component: | MDN | Assignee: | Marc Mutz <mutz> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | NOR | ||
Version: | 1.9.7 | ||
Target Milestone: | --- | ||
Platform: | Debian testing | ||
OS: | Linux | ||
Latest Commit: | Version Fixed In: | ||
Sentry Crash Report: | |||
Attachments: |
diff to solve the problem as I understand it
Proposed, more general fix |
Description
Frank Niethardt
2007-12-12 12:36:28 UTC
I just looked through the source. I think the problem is, that KMFilterAction::SendMDN calls msg->createMDN with KMime::MDN::AutomaticAction. Thats ok, but if this is called every user interaction is skipped. I think in that case kmail should either ask, or just don't send any MDN, as the user discarded (filtered) the message anyway. As I understand KMMessage::createMDN right, it's even worse: if it is said to ignore (what should be mode = 0?) and it is AutomaticAction, it is send too, instead of ignored.... Created attachment 23482 [details]
diff to solve the problem as I understand it
This should do it. Don't have the resources to try it out at the moment.
Frank, thanks for the patch, I'll ask the author of the MDN code to review it. Created attachment 23610 [details]
Proposed, more general fix
> As I understand KMMessage::createMDN right, it's even worse: if it is said to > ignore (what should be mode = 0?) and it is AutomaticAction, it is send too, > instead of ignored.... That is not correct. 'Ignored' is handled near the beginning, of course: > // default: > int mode = mdnConfig.readEntry( "default-policy", 0 ); > if ( !mode || mode < 0 || mode > 3 ) { > // early out for ignore: > setMDNSentState( KMMsgMDNIgnore ); > return 0; > } As for your patch, please send minimal patches. Use the -bB options to diff, e.g. That said, I see no reason, indeed, to not ask the user on automatic actions if he indicated he wants to be asked. Your solution to never send an MDN for mode == Ask && automatic action is wrong, though. It might very well be that no-one calls createMDN() with a == AutomaticAction and allowGUI == true. But this case nevertheless needs to be handled. I've attached a new patch. Please check whether it fixes your problem. As I said, I don't have the resources to compile a kmail right now, but the diff itself looks good. SVN commit 777776 by mutz: Fix MDNs begin sent for automatic actions, when when the user wanted to be asked. BUG: 153904 M +4 -3 kmmessage.cpp WebSVN link: http://websvn.kde.org/?view=rev&revision=777776 |