See ChangeLog

Monotone-Parent: d9b64f2f2d300ee374dbaa78a98f62ce367f4588
Monotone-Revision: 83c63e63da91d2b44db08849dc570ff2029ed74a

Monotone-Author: ludovic@Sophos.ca
Monotone-Date: 2010-03-22T23:06:42
Monotone-Branch: ca.inverse.sogo
maint-2.0.2
Ludovic Marcotte 2010-03-22 23:06:42 +00:00
parent f80d1ab5fa
commit c9c3226988
2 changed files with 29 additions and 6 deletions

View File

@ -1,3 +1,8 @@
2010-03-22 Ludovic Marcotte <lmarcotte@inverse.ca>
* SoObjects/Mailer/SOGoDraftObject.m - we strip
the bcc header prior to sending mails.
2010-03-22 Wolfgang Sourdeau <wsourdeau@inverse.ca>
* UI/Scheduler/UIxCalListingActions.m

View File

@ -1211,11 +1211,12 @@ static NSString *userAgent = @"SOGoMail 1.0";
}
- (NGMutableHashMap *) mimeHeaderMapWithHeaders: (NSDictionary *) _headers
excluding: (NSArray *) _exclude
{
NSString *s, *dateString;
NGMutableHashMap *map;
NSArray *emails;
NSString *s, *dateString;
id from, replyTo;
id from, replyTo;
NSArray *emails;
map = [[[NGMutableHashMap alloc] initWithCapacity:16] autorelease];
@ -1273,10 +1274,20 @@ static NSString *userAgent = @"SOGoMail 1.0";
[self _addHeaders: _headers toHeaderMap: map];
// We remove what we have to...
if (_exclude)
{
int i;
for (i = 0; i < [_exclude count]; i++)
[map removeAllObjectsForKey: [_exclude objectAtIndex: i]];
}
return map;
}
- (NGMimeMessage *) mimeMessageWithHeaders: (NSDictionary *) _headers
excluding: (NSArray *) _exclude
{
NGMutableHashMap *map;
NSArray *bodyParts;
@ -1284,7 +1295,8 @@ static NSString *userAgent = @"SOGoMail 1.0";
message = nil;
map = [self mimeHeaderMapWithHeaders: _headers];
map = [self mimeHeaderMapWithHeaders: _headers
excluding: _exclude];
if (map)
{
[self debugWithFormat: @"MIME Envelope: %@", map];
@ -1313,7 +1325,7 @@ static NSString *userAgent = @"SOGoMail 1.0";
- (NGMimeMessage *) mimeMessage
{
return [self mimeMessageWithHeaders: nil];
return [self mimeMessageWithHeaders: nil excluding: nil];
}
- (NSData *) mimeMessageAsData
@ -1376,7 +1388,13 @@ static NSString *userAgent = @"SOGoMail 1.0";
error = (NSException *) sentFolder;
else
{
message = [self mimeMessageAsData];
// We strip the BCC fields prior sending any mails
NGMimeMessageGenerator *generator;
generator = [[[NGMimeMessageGenerator alloc] init] autorelease];
message = [generator generateMimeFromPart: [self mimeMessageWithHeaders: nil
excluding: [NSArray arrayWithObject: @"bcc"]]];
dd = [[context activeUser] domainDefaults];
error = [[SOGoMailer mailerWithDomainDefaults: dd]
sendMailData: message