Bug 51112

Summary: Reply-to-all only replies to most
Product: [Unmaintained] kmail Reporter: phrensy
Component: generalAssignee: kdepim bugs <kdepim-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Mandrake RPMs   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description phrensy 2002-11-24 02:02:09 UTC
Version:            (using KDE KDE 3.0.3)
Installed from:    Mandrake RPMs
OS:          Linux

When a user clicks "reply-to-all", the recipient list removes addresses that are a subset of the user's address, or which are a superset of the user's address.  For example, if my address is myname@localhost, and I am replying to the following addresses:

readmyname@localhost
name@localhost
test@localhost

kmail will only reply to test@localhost.  It will strip the other two addresses.  I suspect the culprit is the following line in kmmessage.cpp:

if ((*it).find(myAddr,0,false) != -1)

Note that this line shows up in two places.
Comment 1 Eric Rosenberg 2003-06-01 21:20:51 UTC
This happens for me as well. I'm using KMail 1.5.2. 
 
If I send a message to eric@ekrosenberg.com and deric@ekrosenberg.com neither 
address is included in the reply. I think the problem is that the code that tries to 
remove the senders address from the recipient list that the reply-all is going to is 
looking for eric@ekrosenberg.com in the recipients list. Since eric@ekrosenberg.com 
is a substring of deric@ekrosenberg.com both addresses are being removed.  
 
I think if the 2 places where the line "if ((*it).find(myAddr,0,false) != -1)" was changed 
to "if ((*it).find(myAddr,0,false) == 0)" it would work. 
 
If I can figure out how to get KMail to compile I'll try to test it out. 
Comment 2 Eric Rosenberg 2003-06-01 23:20:15 UTC
I uploaded a patch to bug 51195 that also seems to fix this bug. 
Comment 3 Eric Rosenberg 2003-06-03 02:35:26 UTC
Sorry for the bad info in comment #2. The patch that would also fix this bug is attached 
to bug 59195 
Comment 4 Till Adam 2003-06-05 17:14:12 UTC

*** This bug has been marked as a duplicate of 59195 ***