From 81a74f2069bd4032c7f7b258e233789e2cbfb9c7 Mon Sep 17 00:00:00 2001 From: Philip Herbert Date: Mon, 4 Apr 2011 21:56:37 +0000 Subject: [PATCH] fix for foldersync loop, when users calendar is empty and ctag=0 --- calendar/inc/class.calendar_activesync.inc.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/calendar/inc/class.calendar_activesync.inc.php b/calendar/inc/class.calendar_activesync.inc.php index f459307bdf..df41d53743 100644 --- a/calendar/inc/class.calendar_activesync.inc.php +++ b/calendar/inc/class.calendar_activesync.inc.php @@ -952,7 +952,8 @@ class calendar_activesync implements activesync_plugin_write if (!isset($this->calendar)) $this->calendar = new calendar_boupdate(); $ctag = $this->calendar->get_ctag($owner); - + // workaround for syncstate = 0 when calendar is empty causes synctate to not return 0 but array resulting in foldersync loop + if ($ctag == 0) $ctag = 1; $changes = array(); // no change $syncstate_was = $syncstate;