Bug 46185

Summary: AEGYPTEN: detahced sig of mp/signed is shown as attachment in composer
Product: [Applications] kmail Reporter: Marc Mutz <mutz>
Component: encryptionAssignee: kdepim bugs <kdepim-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: coward
Priority: NOR    
Version: 1.4.6   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:

Description Marc Mutz 2002-08-06 15:06:55 UTC
(*** This bug was imported into bugs.kde.org ***)

Package:           kmail
Version:           1.4.6 (using KDE 3.0.2 )
Severity:          normal
Installed from:    compiled sources
Compiler:          gcc version 2.96 20000731 (Mandrake Linux 8.1 2.96-0.63.1mdk)
OS:                Linux (i686) release 2.4.8-26mdk
OS/Compiler notes: 

Just queue a OpenPGP/MIME signed message and then double-click on it in the outbox.

Expected behaviour: the detached sig is removed and not shown in the composer.

Same goes most likely for S/MIME and for the drafts folder.

(Submitted via bugs.kde.org)
(Called from KBugReport dialog)
Comment 1 Ingo Klöcker 2003-02-12 01:30:51 UTC
*** Bug 54505 has been marked as a duplicate of this bug. ***
Comment 2 Ingo Klöcker 2003-06-23 01:01:26 UTC
Subject: kdepim/kmail

CVS commit by kloecker: 

Fix bug 46185: AEGYPTEN: detached sig of mp/signed is shown as attachment in composer
CCMAIL: 46185-fixed@bugs.kde.org


  M +7 -1      kmcomposewin.cpp   1.706


--- kdepim/kmail/kmcomposewin.cpp  #1.705:1.706
@@ -1317,5 +1317,11 @@ void KMComposeWin::setMsg(KMMessage* new
       msgPart = new KMMessagePart;
       mMsg->bodyPart(i, msgPart);
+      QCString mimeType = msgPart->typeStr().lower() + '/'
+                        + msgPart->subtypeStr().lower();
+      // don't add the detached signature as attachment when editting a
+      // PGP/MIME signed message
+      if( mimeType != "application/pgp-signature" ) {
       addAttach(msgPart);
+      }
     }
   } else{