(fix) correctly set flags when replying/forwarding emails using EAS

pull/207/head
Ludovic Marcotte 2016-05-02 09:42:39 -04:00
parent 2a3a575e72
commit cd89b46c01
1 changed files with 30 additions and 24 deletions

View File

@ -2981,7 +2981,7 @@ void handle_eas_terminate(int signum)
[references addObject: [mailObject messageId]];
[map setObject: [references componentsJoinedByString:@" "] forKey: @"references"];
[map setObject: [references componentsJoinedByString: @" "] forKey: @"references"];
}
else
{
@ -3156,15 +3156,13 @@ void handle_eas_terminate(int signum)
bodyPart = [[[NGMimeBodyPart alloc] initWithHeader: map] autorelease];
fdata = [[NGMimeFileData alloc] initWithBytes:[bodydata bytes] length:[bodydata length]];
[bodyPart setBody: fdata];
RELEASE(fdata);
[body addBodyPart: bodyPart];
}
}
}
}
} // if (isSmartForward)
[messageToSend setBody: body];
@ -3180,6 +3178,14 @@ void handle_eas_terminate(int signum)
[theResponse setStatus: 500];
[theResponse appendContentString: @"FATAL ERROR occured during SmartForward"];
}
else if (!isSmartForward)
{
[mailObject addFlags: @"Answered"];
}
else
{
[mailObject addFlags: @"$Forwarded"];
}
}
else
{