From 95680b33a14dd3e7e2ee396e35645e7039357c94 Mon Sep 17 00:00:00 2001 From: Ludovic Marcotte Date: Thu, 20 Dec 2018 09:12:44 -0500 Subject: [PATCH] (fix) better handle bogus DTStart values over EAS --- ActiveSync/SOGoMailObject+ActiveSync.m | 3 ++- NEWS | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/ActiveSync/SOGoMailObject+ActiveSync.m b/ActiveSync/SOGoMailObject+ActiveSync.m index dfe407e72..60d4f9bd5 100644 --- a/ActiveSync/SOGoMailObject+ActiveSync.m +++ b/ActiveSync/SOGoMailObject+ActiveSync.m @@ -35,6 +35,7 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #import #import #import +#import #import #import @@ -970,7 +971,7 @@ struct GlobalObjectId { if ([event startDate]) [s appendFormat: @"%@", [[event startDate] activeSyncRepresentationInContext: context]]; - if ([event timeStampAsDate]) + if ([event timeStampAsDate] && [[event timeStampAsDate] dayOfMonth] > 0 && [[event timeStampAsDate] monthOfYear] > 0) [s appendFormat: @"%@", [[event timeStampAsDate] activeSyncRepresentationInContext: context]]; else if ([event created]) [s appendFormat: @"%@", [[event created] activeSyncRepresentationInContext: context]]; diff --git a/NEWS b/NEWS index 6b53d6b08..6978113ae 100644 --- a/NEWS +++ b/NEWS @@ -21,6 +21,7 @@ Bug fixes - [eas] strip '<>' from bodyId and when forwarding mails - [eas] fix search on for Outlook application (#4605 and #4607) - [eas] improve search operations and results fetching + - [eas] better handle bogus DTStart values 4.0.4 (2018-10-23) ------------------