diff --git a/OpenChange/MAPIStoreMailVolatileMessage.m b/OpenChange/MAPIStoreMailVolatileMessage.m index 73476bef7..aba0d8a49 100644 --- a/OpenChange/MAPIStoreMailVolatileMessage.m +++ b/OpenChange/MAPIStoreMailVolatileMessage.m @@ -865,7 +865,7 @@ MakeMessageBody (NSDictionary *mailProperties, NSDictionary *attachmentParts, NS NSMutableArray *recipientEmails; NSArray *list; NSString *recId, *from, *msgClass; - NSUInteger count; + enum ulRecipClass type; SOGoUser *activeUser; SOGoDomainDefaults *dd; NSException *error; @@ -881,9 +881,9 @@ MakeMessageBody (NSDictionary *mailProperties, NSDictionary *attachmentParts, NS recipientEmails = [NSMutableArray arrayWithCapacity: 32]; recipients = [properties objectForKey: @"recipients"]; - for (count = 0; count < 3; count++) + for (type = MAPI_ORIG; type <= MAPI_BCC; type++) { - recId = recTypes[count]; + recId = recTypes[type]; list = [recipients objectForKey: recId]; [recipientEmails addObjectsFromArray: [list objectsForKey: @"email"