[evolution-kolab/ek-wip-porting] libekolab: reformatted sources



commit b7f3b8cc38bdd0daef78d4cd01a23a4b9606b02c
Author: Christian Hilberg <hilberg kernelconcepts de>
Date:   Wed Dec 7 17:45:33 2011 +0100

    libekolab: reformatted sources
    
    * use proper indentation
    * removed trailing whitespace
    * removed excess trailing newlines

 src/libekolab/kolab-folder-summary.c      |    2 +-
 src/libekolab/kolab-mail-access.c         |  336 ++++++------
 src/libekolab/kolab-mail-handle.c         |  476 +++++++++---------
 src/libekolab/kolab-mail-imap-client.c    |  170 +++---
 src/libekolab/kolab-mail-info-db-record.c |    2 +-
 src/libekolab/kolab-mail-info-db.c        |  306 ++++++------
 src/libekolab/kolab-mail-mime-builder.c   |   54 +-
 src/libekolab/kolab-mail-side-cache.c     |   94 ++--
 src/libekolab/kolab-mail-summary.c        |   72 ++--
 src/libekolab/kolab-mail-synchronizer.c   |  820 ++++++++++++++--------------
 src/libekolab/kolab-settings-handler.c    |  116 ++--
 src/libekolab/kolab-util-backend.c        |   42 +-
 src/libekolab/kolab-util-backend.h        |    8 +-
 13 files changed, 1249 insertions(+), 1249 deletions(-)
---
diff --git a/src/libekolab/kolab-folder-summary.c b/src/libekolab/kolab-folder-summary.c
index 5f5e899..71e6e5e 100644
--- a/src/libekolab/kolab-folder-summary.c
+++ b/src/libekolab/kolab-folder-summary.c
@@ -266,7 +266,7 @@ kolab_folder_summary_dump (const KolabFolderSummary *summary)
 	                                                KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY)
 	         );
 
-folder_summary_skip:
+ folder_summary_skip:
 	g_debug ("\n%s: **** FolderSummary End ****\n", __func__);
 }
 
diff --git a/src/libekolab/kolab-mail-access.c b/src/libekolab/kolab-mail-access.c
index a75b3df..cb480fc 100644
--- a/src/libekolab/kolab-mail-access.c
+++ b/src/libekolab/kolab-mail-access.c
@@ -12,12 +12,12 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
@@ -56,7 +56,7 @@ struct _KolabMailAccessPrivate
 	KolabMailMimeBuilder *mimebuilder;
 	KolabMailSideCache *sidecache;
 	KolabMailSynchronizer *synchronizer;
-	
+
 	KolabMailAccessState *state;
 	GHashTable *stranstbl;
 
@@ -99,7 +99,7 @@ kolab_mail_access_init (KolabMailAccess *object)
 	KolabMailAccessPrivate *priv = NULL;
 
 	g_assert (KOLAB_IS_MAIL_ACCESS (object));
-	
+
 	self = object;
 	priv = KOLAB_MAIL_ACCESS_PRIVATE (self);
 
@@ -110,7 +110,7 @@ kolab_mail_access_init (KolabMailAccess *object)
 	priv->mimebuilder = KOLAB_MAIL_MIME_BUILDER (g_object_new (KOLAB_TYPE_MAIL_MIME_BUILDER, NULL));
 	priv->sidecache = KOLAB_MAIL_SIDE_CACHE (g_object_new (KOLAB_TYPE_MAIL_SIDE_CACHE, NULL));
 	priv->synchronizer = KOLAB_MAIL_SYNCHRONIZER (g_object_new (KOLAB_TYPE_MAIL_SYNCHRONIZER, NULL));
-	
+
 	priv->state = kolab_mail_access_state_new ();
 	priv->stranstbl = kolab_mail_access_new_strans_table ();
 
@@ -130,7 +130,7 @@ kolab_mail_access_dispose (GObject *object)
 
 	if (priv->client != NULL)
 		g_object_unref (priv->client);
-	
+
 	if (priv->infodb != NULL)
 		g_object_unref (priv->infodb);
 
@@ -164,7 +164,7 @@ kolab_mail_access_finalize (GObject *object)
 
 	self = KOLAB_MAIL_ACCESS (object);
 	priv = KOLAB_MAIL_ACCESS_PRIVATE (self);
-	
+
 	kolab_mail_access_state_free (priv->state);
 
 	if (priv->handles)
@@ -198,7 +198,7 @@ kolab_mail_access_foldername_new_from_sourcename (KolabMailAccess *self,
 	gchar *foldername = NULL;
 	gboolean exists = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	/* sourcename may be NULL */
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, NULL);
@@ -207,7 +207,7 @@ kolab_mail_access_foldername_new_from_sourcename (KolabMailAccess *self,
 
 	if (sourcename == NULL)
 		return NULL;
-	
+
 	/* map Evo sourcename to Kolab foldername */
 	foldername = kolab_util_backend_foldername_new_from_sourcename (sourcename,
 	                                                                &tmp_err);
@@ -261,7 +261,7 @@ kolab_mail_access_local_handle_attach_summary (KolabMailAccess *self,
 	summary = kolab_mail_handle_get_summary (kmailhandle);
 	if (summary != NULL)
 		return TRUE;
-	
+
 	uid = kolab_mail_handle_get_uid (kmailhandle);
 	if (uid == NULL) {
 		g_set_error (err,
@@ -280,7 +280,7 @@ kolab_mail_access_local_handle_attach_summary (KolabMailAccess *self,
 		             __func__, uid);
 		return FALSE;
 	}
-	
+
 	new_summary = kolab_mail_info_db_query_mail_summary (priv->infodb,
 	                                                     uid,
 	                                                     foldername,
@@ -299,7 +299,7 @@ kolab_mail_access_local_handle_attach_summary (KolabMailAccess *self,
 		g_debug ("%s: UID (%s) no summary info found in DB",
 		         __func__, uid);
 		return TRUE;
-		
+
 	}
 
 	ok = kolab_mail_handle_set_summary (kmailhandle,
@@ -316,8 +316,8 @@ kolab_mail_access_local_handle_attach_summary (KolabMailAccess *self,
 
 static gboolean
 kolab_mail_access_update_handles_from_infodb (KolabMailAccess *self,
-		                              const gchar *foldername,
-		                              const gchar *sexp,
+                                              const gchar *foldername,
+                                              const gchar *sexp,
                                               GError **err)
 {
 	KolabMailAccessPrivate *priv = NULL;
@@ -325,7 +325,7 @@ kolab_mail_access_update_handles_from_infodb (KolabMailAccess *self,
 	GList *changed_uids_lst = NULL;
 	GList *changed_uids_lst_ptr = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (foldername != NULL);
 	/* sexp may be NULL */
@@ -344,7 +344,7 @@ kolab_mail_access_update_handles_from_infodb (KolabMailAccess *self,
 		                     g_strdup (foldername),
 		                     handles_tbl);
 	}
-	
+
 	/* get list of all changed uids from InfoDb */
 	changed_uids_lst = kolab_mail_info_db_query_changed_uids (priv->infodb,
 	                                                          foldername,
@@ -403,7 +403,7 @@ kolab_mail_access_local_handle_get_by_uid (KolabMailAccess *self,
 		                     g_strdup (foldername),
 		                     handles_tbl);
 	}
-	
+
 	local_handle = g_hash_table_lookup (handles_tbl, uid);
 	if (local_handle == NULL) {
 		/* lookup UID in InfoDb, create new handle */
@@ -424,8 +424,8 @@ kolab_mail_access_local_handle_get_by_uid (KolabMailAccess *self,
 		             __func__, uid, foldername);
 		return NULL;
 	}
-	
-	if (local_handle == NULL) { 
+
+	if (local_handle == NULL) {
 		g_debug ("%s: UID (%s) Folder (%s) not found in database",
 		         __func__, uid, foldername);
 	}
@@ -469,7 +469,7 @@ kolab_mail_access_local_handle_get (KolabMailAccess *self,
 		             __func__, uid);
 		return NULL;
 	}
-	
+
 	local_handle = kolab_mail_access_local_handle_get_by_uid (self,
 	                                                          uid,
 	                                                          foldername,
@@ -479,7 +479,7 @@ kolab_mail_access_local_handle_get (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return NULL;
 	}
-	
+
 	return local_handle;
 }
 
@@ -505,7 +505,7 @@ kolab_mail_access_local_store (KolabMailAccess *self,
 	gboolean ok = FALSE;
 	gboolean do_store = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	if (kmailhandle != NULL)
 		g_assert (KOLAB_IS_MAIL_HANDLE (kmailhandle));
@@ -557,14 +557,14 @@ kolab_mail_access_local_store (KolabMailAccess *self,
 		                      kmailhandle);
 	}
 	local_handle = kmailhandle;
-	
+
 	/* convert handle payload data to Kolab_conv_mail */
 	ok = kolab_mail_handle_convert_eds_to_kconvmail (local_handle, &tmp_err);
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	/* TODO can we switch from full summaries table to simple UID list here ? */
 	imap_summaries = kolab_mail_imap_client_query_summaries (priv->client,
 	                                                         foldername,
@@ -589,7 +589,7 @@ kolab_mail_access_local_store (KolabMailAccess *self,
 	}
 	if (tmp_err != NULL) {
 		g_propagate_error (err, tmp_err);
-		return FALSE;		
+		return FALSE;
 	}
 
 	/* store transaction start */
@@ -614,15 +614,15 @@ kolab_mail_access_local_store (KolabMailAccess *self,
 
 	if (do_store) {
 		ok = kolab_mail_side_cache_store (priv->sidecache,
-			                          local_handle,
-			                          foldername,
-			                          &tmp_err);
+		                                  local_handle,
+		                                  foldername,
+		                                  &tmp_err);
 		if (ok) {
 			kolab_mail_handle_set_cache_location (local_handle,
-					                      KOLAB_OBJECT_CACHE_LOCATION_SIDE);
+			                                      KOLAB_OBJECT_CACHE_LOCATION_SIDE);
 		} else {
 			g_warning ("%s offline mode failure: %s",
-				   __func__, tmp_err->message);
+			           __func__, tmp_err->message);
 			g_error_free (tmp_err);
 			tmp_err = NULL;
 			offline_fail = TRUE;
@@ -639,7 +639,7 @@ kolab_mail_access_local_store (KolabMailAccess *self,
 		if (ok) {
 			sync_opmode = KOLAB_MAIL_ACCESS_OPMODE_ONLINE;
 			kolab_mail_handle_set_cache_location (local_handle,
-					                      KOLAB_OBJECT_CACHE_LOCATION_IMAP);
+			                                      KOLAB_OBJECT_CACHE_LOCATION_IMAP);
 		} else {
 			g_warning ("%s online mode failure: %s",
 			           __func__, tmp_err->message);
@@ -677,7 +677,7 @@ kolab_mail_access_local_store (KolabMailAccess *self,
 	}
 
 	kolab_mail_info_db_record_free (record);
-	
+
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
 		return FALSE;
@@ -697,9 +697,9 @@ kolab_mail_access_local_store (KolabMailAccess *self,
 
 static gboolean
 kolab_mail_access_local_delete (KolabMailAccess *self,
-                               KolabMailHandle *kmailhandle,
-                               const gchar *foldername,
-                               GError **err)
+                                KolabMailHandle *kmailhandle,
+                                const gchar *foldername,
+                                GError **err)
 {
 	KolabMailAccessPrivate *priv = NULL;
 	KolabObjectCacheLocation location = KOLAB_OBJECT_CACHE_LOCATION_NONE;
@@ -722,12 +722,12 @@ kolab_mail_access_local_delete (KolabMailAccess *self,
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
 	priv = KOLAB_MAIL_ACCESS_PRIVATE (self);
-	
+
 	if (kmailhandle != NULL) {
 		/* check whether we have a summary for the mail handle */
 		ok = kolab_mail_access_local_handle_attach_summary (self,
-			                                            kmailhandle,
-			                                            &tmp_err);
+		                                                    kmailhandle,
+		                                                    &tmp_err);
 		if (! ok) {
 			g_propagate_error (err, tmp_err);
 			return FALSE;
@@ -756,13 +756,13 @@ kolab_mail_access_local_delete (KolabMailAccess *self,
 			g_propagate_error (err, tmp_err);
 			return FALSE;
 		}
-		
+
 		location = kolab_folder_summary_get_uint_field (summary,
 		                                                KOLAB_FOLDER_SUMMARY_UINT_FIELD_CACHE_LOCATION);
 		kolab_folder_summary_free (summary);
 		foldername_del = g_strdup (foldername);
 	}
-	
+
 	/* TODO can we switch from full summaries table to simple UID list here ? */
 	imap_summaries = kolab_mail_imap_client_query_summaries (priv->client,
 	                                                         foldername,
@@ -788,7 +788,7 @@ kolab_mail_access_local_delete (KolabMailAccess *self,
 	}
 	if (tmp_err != NULL) {
 		g_propagate_error (err, tmp_err);
-		return FALSE;		
+		return FALSE;
 	}
 
 	/* delete transaction start */
@@ -822,10 +822,10 @@ kolab_mail_access_local_delete (KolabMailAccess *self,
 					 * with Kontact reference behaviour)
 					 */
 					ok = kolab_mail_imap_client_delete (priv->client,
-								            kmailhandle,
+					                                    kmailhandle,
 					                                    FALSE, /* try not only by IMAP UID */
 					                                    FALSE, /* folder already updated */
-							                    &tmp_err);
+					                                    &tmp_err);
 				} else {
 					ok = TRUE;
 				}
@@ -836,17 +836,17 @@ kolab_mail_access_local_delete (KolabMailAccess *self,
 				 *      really delete folders on the server)
 				 */
 				ok = kolab_mail_imap_client_delete_folder (priv->client,
-					                                   foldername_del,
-					                                   &tmp_err);
+				                                           foldername_del,
+				                                           &tmp_err);
 			}
 			if (ok) {
 				sync_opmode = KOLAB_MAIL_ACCESS_OPMODE_ONLINE;
 				if (kmailhandle != NULL)
 					kolab_mail_handle_unset_cache_location (kmailhandle,
-							                        KOLAB_OBJECT_CACHE_LOCATION_IMAP);
+					                                        KOLAB_OBJECT_CACHE_LOCATION_IMAP);
 			} else {
 				g_warning ("%s: online mode failure: %s",
-					   __func__, tmp_err->message);
+				           __func__, tmp_err->message);
 				g_error_free (tmp_err);
 				tmp_err = NULL;
 				online_ok = FALSE;
@@ -856,19 +856,19 @@ kolab_mail_access_local_delete (KolabMailAccess *self,
 		if (online_ok && (location & KOLAB_OBJECT_CACHE_LOCATION_SIDE)) {
 			if (kmailhandle != NULL)
 				ok = kolab_mail_side_cache_delete (priv->sidecache,
-					                           kmailhandle,
-					                           &tmp_err);
+				                                   kmailhandle,
+				                                   &tmp_err);
 			else
 				ok = kolab_mail_side_cache_delete_folder (priv->sidecache,
-					                                  foldername_del,
-					                                  &tmp_err);
+				                                          foldername_del,
+				                                          &tmp_err);
 			if (ok) {
 				if (kmailhandle != NULL)
 					kolab_mail_handle_unset_cache_location (kmailhandle,
-							                        KOLAB_OBJECT_CACHE_LOCATION_SIDE);
+					                                        KOLAB_OBJECT_CACHE_LOCATION_SIDE);
 			} else {
 				g_warning ("%s offline mode failure: %s",
-					   __func__, tmp_err->message);
+				           __func__, tmp_err->message);
 				g_error_free (tmp_err);
 				tmp_err = NULL;
 				offline_ok = FALSE;
@@ -879,24 +879,24 @@ kolab_mail_access_local_delete (KolabMailAccess *self,
 	/* transaction finalization */
 	if (online_ok && offline_ok)
 		ok = kolab_mail_synchronizer_transaction_commit (priv->synchronizer,
-			                                         sync_opmode,
-			                                         KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_DELETE,
-			                                         kmailhandle,
-			                                         foldername_del,
+		                                                 sync_opmode,
+		                                                 KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_DELETE,
+		                                                 kmailhandle,
+		                                                 foldername_del,
 		                                                 record,
-			                                         &tmp_err);
+		                                                 &tmp_err);
 	else
 		ok = kolab_mail_synchronizer_transaction_abort (priv->synchronizer,
 		                                                sync_opmode,
-				                                KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_DELETE,
-				                                kmailhandle,
-				                                foldername_del,
+		                                                KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_DELETE,
+		                                                kmailhandle,
+		                                                foldername_del,
 		                                                record,
-				                                &tmp_err);
+		                                                &tmp_err);
 	kolab_mail_info_db_record_free (record);
 	if (foldername_del != NULL)
 		g_free (foldername_del);
-	
+
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
 		return FALSE;
@@ -935,7 +935,7 @@ kolab_mail_access_strans_configured_offline (KolabMailAccess *self,
 	GList *folders_lst_ptr = NULL;
 	gboolean ok = TRUE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -958,7 +958,7 @@ kolab_mail_access_strans_configured_offline (KolabMailAccess *self,
 	                                       g_str_equal,
 	                                       g_free,
 	                                       kolab_util_glib_ghashtable_gdestroy);
-	
+
 	g_debug ("KolabMailAccess: changing state: configured->offline");
 
 	/* bring up infrastructure */
@@ -970,7 +970,7 @@ kolab_mail_access_strans_configured_offline (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	/* KolabMailInfoDb *infodb */
 	ok = kolab_mail_info_db_bringup (priv->infodb,
 	                                 &tmp_err);
@@ -1023,9 +1023,9 @@ kolab_mail_access_strans_configured_offline (KolabMailAccess *self,
 	while (folders_lst_ptr != NULL) {
 		gchar *foldername = (gchar *)(folders_lst_ptr->data);
 		ok = kolab_mail_access_update_handles_from_infodb (self,
-			                                           foldername,
-			                                           NULL, /* sexp */
-			                                           &tmp_err);
+		                                                   foldername,
+		                                                   NULL, /* sexp */
+		                                                   &tmp_err);
 		if (! ok)
 			break;
 		folders_lst_ptr = g_list_next (folders_lst_ptr);
@@ -1035,7 +1035,7 @@ kolab_mail_access_strans_configured_offline (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	g_debug ("KolabMailAccess: new state: offline");
 
 	priv->state->opmode = KOLAB_MAIL_ACCESS_OPMODE_OFFLINE;
@@ -1051,7 +1051,7 @@ kolab_mail_access_strans_offline_online (KolabMailAccess *self,
 	GList *folders_lst_ptr = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1066,7 +1066,7 @@ kolab_mail_access_strans_offline_online (KolabMailAccess *self,
 		             __func__);
 		return FALSE;
 	}
-	
+
 	g_debug ("KolabMailAccess: changing state: offline->online");
 
 	/* get infrastructure into online operation */
@@ -1078,7 +1078,7 @@ kolab_mail_access_strans_offline_online (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	/* sync pim metadata */
 	ok = kolab_mail_synchronizer_info_sync (priv->synchronizer,
 	                                        KOLAB_MAIL_ACCESS_OPMODE_ONLINE,
@@ -1113,9 +1113,9 @@ kolab_mail_access_strans_offline_online (KolabMailAccess *self,
 	while (folders_lst_ptr != NULL) {
 		gchar *foldername = (gchar *)(folders_lst_ptr->data);
 		ok = kolab_mail_access_update_handles_from_infodb (self,
-			                                           foldername,
-			                                           NULL, /* sexp */
-			                                           &tmp_err);
+		                                                   foldername,
+		                                                   NULL, /* sexp */
+		                                                   &tmp_err);
 		if (! ok)
 			break;
 		folders_lst_ptr = g_list_next (folders_lst_ptr);
@@ -1139,7 +1139,7 @@ kolab_mail_access_strans_configured_online (KolabMailAccess *self,
 	KolabMailAccessPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1150,7 +1150,7 @@ kolab_mail_access_strans_configured_online (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	ok = kolab_mail_access_strans_offline_online (self, &tmp_err);
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
@@ -1169,7 +1169,7 @@ kolab_mail_access_strans_online_offline (KolabMailAccess *self,
 	GList *folders_lst_ptr = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1184,7 +1184,7 @@ kolab_mail_access_strans_online_offline (KolabMailAccess *self,
 		             __func__);
 		return FALSE;
 	}
-	
+
 	g_debug ("KolabMailAccess: changing state: online->offline");
 
 	/* get infrastructure into offline operation */
@@ -1233,7 +1233,7 @@ kolab_mail_access_strans_online_offline (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	folders_lst = kolab_mail_info_db_query_foldernames (priv->infodb,
 	                                                    &tmp_err);
 	if (tmp_err != NULL) {
@@ -1246,9 +1246,9 @@ kolab_mail_access_strans_online_offline (KolabMailAccess *self,
 	while (folders_lst_ptr != NULL) {
 		gchar *foldername = (gchar *)(folders_lst_ptr->data);
 		ok = kolab_mail_access_update_handles_from_infodb (self,
-			                                           foldername,
-			                                           NULL, /* sexp */
-			                                           &tmp_err);
+		                                                   foldername,
+		                                                   NULL, /* sexp */
+		                                                   &tmp_err);
 		if (! ok)
 			break;
 		folders_lst_ptr = g_list_next (folders_lst_ptr);
@@ -1258,7 +1258,7 @@ kolab_mail_access_strans_online_offline (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	g_debug ("KolabMailAccess: new state: offline");
 
 	priv->state->opmode = KOLAB_MAIL_ACCESS_OPMODE_OFFLINE;
@@ -1272,7 +1272,7 @@ kolab_mail_access_strans_offline_shutdown (KolabMailAccess *self,
 	KolabMailAccessPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1287,11 +1287,11 @@ kolab_mail_access_strans_offline_shutdown (KolabMailAccess *self,
 		             __func__);
 		return FALSE;
 	}
-	
+
 	g_debug ("KolabMailAccess: changing state: offline->shutdown");
 
 	/* shut down infrastructure */
-	
+
 	/* TODO KolabMailSynchronizer needs to sync
 	 *      - KolabMailInfoDb
 	 *      with
@@ -1363,7 +1363,7 @@ kolab_mail_access_strans_online_shutdown (KolabMailAccess *self,
 	KolabMailAccessPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1374,7 +1374,7 @@ kolab_mail_access_strans_online_shutdown (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	ok = kolab_mail_access_strans_offline_shutdown (self, &tmp_err);
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
@@ -1389,7 +1389,7 @@ kolab_mail_access_strans_shutdown_configured (KolabMailAccess *self,
                                               GError **err)
 {
 	KolabMailAccessPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1404,11 +1404,11 @@ kolab_mail_access_strans_shutdown_configured (KolabMailAccess *self,
 		             __func__);
 		return FALSE;
 	}
-	
+
 	g_debug ("KolabMailAccess: changing state: shutdown->configured");
 
 	/* TODO implement me */
-	
+
 	g_debug ("KolabMailAccess: new state: configured");
 
 	priv->state->opmode = KOLAB_MAIL_ACCESS_OPMODE_CONFIGURED;
@@ -1421,13 +1421,13 @@ kolab_mail_access_new_strans_table (void)
 	GHashTable *stranstbl = NULL;
 	GHashTable *tmp_tbl = NULL;
 	KolabMailAccessSTFWrap *tmp_stf = NULL;
-	
+
 	/* state transition function table */
 	stranstbl = g_hash_table_new_full (g_int_hash,
 	                                   g_int_equal,
 	                                   NULL,
 	                                   kolab_util_glib_ghashtable_gdestroy);
-	
+
 	/* --- transitions from CONFIGURED state --- */
 	tmp_tbl = g_hash_table_new_full (g_int_hash, g_int_equal, NULL, g_free);
 	/* configured -> offline */
@@ -1451,13 +1451,13 @@ kolab_mail_access_new_strans_table (void)
 	tmp_tbl = g_hash_table_new_full (g_int_hash, g_int_equal, NULL, g_free);
 	/* offline -> online */
 	tmp_stf = g_new0 (KolabMailAccessSTFWrap, 1);
-	tmp_stf->fn = kolab_mail_access_strans_offline_online;	
+	tmp_stf->fn = kolab_mail_access_strans_offline_online;
 	g_hash_table_insert (tmp_tbl,
 	                     &opmode_values[KOLAB_MAIL_ACCESS_OPMODE_ONLINE],
 	                     tmp_stf);
 	/* offline -> shutdown */
 	tmp_stf = g_new0 (KolabMailAccessSTFWrap, 1);
-	tmp_stf->fn = kolab_mail_access_strans_offline_shutdown;	
+	tmp_stf->fn = kolab_mail_access_strans_offline_shutdown;
 	g_hash_table_insert (tmp_tbl,
 	                     &opmode_values[KOLAB_MAIL_ACCESS_OPMODE_SHUTDOWN],
 	                     tmp_stf);
@@ -1509,7 +1509,7 @@ kolab_mail_access_get_strans_func (KolabMailAccess *self,
 	KolabMailAccessPrivate *priv = NULL;
 	KolabMailAccessSTFWrap *stf = NULL;
 	GHashTable *tbl = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert ((opmode > KOLAB_MAIL_ACCESS_OPMODE_INVAL) &&
 	          (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE));
@@ -1522,9 +1522,9 @@ kolab_mail_access_get_strans_func (KolabMailAccess *self,
 	                           &opmode_values[priv->state->opmode]);
 	if (tbl == NULL) {
 		g_set_error (err,
-			     KOLAB_BACKEND_ERROR,
-			     KOLAB_BACKEND_ERROR_STATE_WRONG_FOR_OP,
-			     "%s: no transition from KolabMailAccessOpmodeID [%i]",
+		             KOLAB_BACKEND_ERROR,
+		             KOLAB_BACKEND_ERROR_STATE_WRONG_FOR_OP,
+		             "%s: no transition from KolabMailAccessOpmodeID [%i]",
 		             __func__,
 		             priv->state->opmode);
 		return NULL;
@@ -1534,14 +1534,14 @@ kolab_mail_access_get_strans_func (KolabMailAccess *self,
 	stf = (KolabMailAccessSTFWrap*) g_hash_table_lookup (tbl, &opmode_values[opmode]);
 	if (stf == NULL) {
 		g_set_error (err,
-			     KOLAB_BACKEND_ERROR,
-			     KOLAB_BACKEND_ERROR_STATE_WRONG_FOR_OP,
-			     "%s: no transition from KolabMailAccessOpmodeID [%i]->[%i]",
+		             KOLAB_BACKEND_ERROR,
+		             KOLAB_BACKEND_ERROR_STATE_WRONG_FOR_OP,
+		             "%s: no transition from KolabMailAccessOpmodeID [%i]->[%i]",
 		             __func__,
 		             priv->state->opmode,
 		             opmode);
 	}
-	
+
 	return stf->fn;
 }
 
@@ -1575,11 +1575,11 @@ kolab_mail_access_configure (KolabMailAccess *self,
 	/* KolabSettingsHandler needs to live for the lifetime of
 	 * KolabMailAccess
 	 */
-	
+
 	KolabMailAccessPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (ksettings));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1598,7 +1598,7 @@ kolab_mail_access_configure (KolabMailAccess *self,
 	/* cannot reconfigure a KolabMailAccess, create a new object instead */
 	if (priv->state->opmode > KOLAB_MAIL_ACCESS_OPMODE_NEW)
 		return TRUE;
-	
+
 	if (priv->ksettings == NULL) {
 		g_object_ref (ksettings); /* unref'd in dispose() */
 		priv->ksettings = ksettings;
@@ -1715,7 +1715,7 @@ kolab_mail_access_bringup (KolabMailAccess *self,
 {
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1726,7 +1726,7 @@ kolab_mail_access_bringup (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	return TRUE;
 }
 
@@ -1757,7 +1757,7 @@ kolab_mail_access_shutdown (KolabMailAccess *self,
 {
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1768,7 +1768,7 @@ kolab_mail_access_shutdown (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	return TRUE;
 }
 
@@ -1815,7 +1815,7 @@ kolab_mail_access_set_opmode (KolabMailAccess *self,
 	KolabMailAccessStateTransitionFunc strans_fn = NULL;
 	gboolean strans_ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert ((opmode > KOLAB_MAIL_ACCESS_OPMODE_INVAL) &&
 	          (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE));
@@ -1826,7 +1826,7 @@ kolab_mail_access_set_opmode (KolabMailAccess *self,
 	/* check whether we are in required opmode already */
 	if (opmode == priv->state->opmode)
 		return TRUE;
-	
+
 	/* get transition function for (current opmode) -> (opmode) */
 	strans_fn = kolab_mail_access_get_strans_func (self, opmode, &tmp_err);
 	if (strans_fn == NULL) {
@@ -1840,7 +1840,7 @@ kolab_mail_access_set_opmode (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	/* TODO implement me
 	 *
 	 * object(s) state
@@ -1877,10 +1877,10 @@ kolab_mail_access_set_opmode (KolabMailAccess *self,
  */
 KolabMailAccessOpmodeID
 kolab_mail_access_get_opmode (KolabMailAccess *self,
-                             GError **err)
+                              GError **err)
 {
 	KolabMailAccessPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, KOLAB_MAIL_ACCESS_OPMODE_INVAL);
 
@@ -1895,7 +1895,7 @@ kolab_mail_access_get_opmode (KolabMailAccess *self,
 	 *   (i.e. full-check within KolabMailImapClient)
 	 * - combine both
 	 */
-	
+
 	return priv->state->opmode;
 }
 
@@ -1938,7 +1938,7 @@ kolab_mail_access_query_uids (KolabMailAccess *self,
 	GList *uids = NULL;
 	gchar *foldername = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (sourcename != NULL);
 	/* sexp may be NULL */
@@ -1954,7 +1954,7 @@ kolab_mail_access_query_uids (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return NULL;
 	}
-	
+
 	/* query KolabMailInfoDb for UIDs */
 	uids = kolab_mail_info_db_query_uids (priv->infodb,
 	                                      foldername,
@@ -1965,7 +1965,7 @@ kolab_mail_access_query_uids (KolabMailAccess *self,
 	g_free (foldername);
 	if (tmp_err != NULL) {
 		g_propagate_error (err, tmp_err);
-		return NULL;		
+		return NULL;
 	}
 
 	return uids;
@@ -2026,17 +2026,17 @@ kolab_mail_access_query_changed_uids (KolabMailAccess *self,
 
 	if (priv->state->opmode > KOLAB_MAIL_ACCESS_OPMODE_OFFLINE) {
 		ok = kolab_mail_synchronizer_info_sync (priv->synchronizer,
-			                                KOLAB_MAIL_ACCESS_OPMODE_ONLINE,
+		                                        KOLAB_MAIL_ACCESS_OPMODE_ONLINE,
 		                                        foldername,
-			                                &tmp_err);
+		                                        &tmp_err);
 		if (! ok) {
 			g_propagate_error (err, tmp_err);
 			return NULL;
 		}
 		ok = kolab_mail_access_update_handles_from_infodb (self,
-			                                           foldername,
-			                                           sexp,
-			                                           &tmp_err);
+		                                                   foldername,
+		                                                   sexp,
+		                                                   &tmp_err);
 		if (! ok) {
 			g_propagate_error (err, tmp_err);
 			return NULL;
@@ -2105,8 +2105,8 @@ kolab_mail_access_get_handle (KolabMailAccess *self,
 
 	/* map Evo calendar name to Kolab folder name */
 	foldername = kolab_mail_access_foldername_new_from_sourcename (self,
-		                                                       sourcename,
-		                                                       &tmp_err);
+	                                                               sourcename,
+	                                                               &tmp_err);
 	if (tmp_err != NULL) {
 		g_propagate_error (err, tmp_err);
 		return NULL;
@@ -2124,7 +2124,7 @@ kolab_mail_access_get_handle (KolabMailAccess *self,
 	}
 
 	handle = g_hash_table_lookup (handles_tbl, uid);
-	
+
 	if (handle == NULL) {
 		handle = kolab_mail_synchronizer_handle_new_from_infodb (priv->synchronizer,
 		                                                         uid,
@@ -2136,7 +2136,7 @@ kolab_mail_access_get_handle (KolabMailAccess *self,
 		}
 		handle_is_new = TRUE;
 	}
-	
+
 	if (handle == NULL) {
 		g_debug ("%s: UID (%s) Folder (%s) unknown",
 		         __func__, uid, foldername);
@@ -2145,7 +2145,7 @@ kolab_mail_access_get_handle (KolabMailAccess *self,
 
 	if (handle_is_new) {
 		g_debug ("%s: UID (%s) created new handle from InfoDb",
-			 __func__, uid);
+		         __func__, uid);
 		g_assert (KOLAB_IS_MAIL_HANDLE (handle));
 		g_hash_table_insert (handles_tbl, g_strdup (uid), handle);
 	}
@@ -2160,7 +2160,7 @@ kolab_mail_access_get_handle (KolabMailAccess *self,
 		}
 	}
 	g_free (foldername);
-	
+
 	return handle;
 }
 
@@ -2209,7 +2209,7 @@ kolab_mail_access_get_handle (KolabMailAccess *self,
  *   <listitem>Handle precondition: must be complete</listitem>
  *   <listitem>Handle postcondition: now INVALID and owned by #KolabMailAccess</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: TRUE on success,
  *          FALSE if local caching or conversion of the data failed (with @err set)
  */
@@ -2232,7 +2232,7 @@ kolab_mail_access_store_handle (KolabMailAccess *self,
 	KolabFolderSummary *folder_summary = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (KOLAB_IS_MAIL_HANDLE (kmailhandle));
 	g_assert (sourcename != NULL);
@@ -2251,14 +2251,14 @@ kolab_mail_access_store_handle (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	/* handle data */
 	handle_fn = kolab_mail_handle_get_foldername (kmailhandle);
 	if (handle_fn == NULL) {
 		kolab_mail_handle_set_foldername (kmailhandle, sourcename_fn);
 		handle_fn = kolab_mail_handle_get_foldername (kmailhandle);
 	}
-	
+
 	summary = kolab_mail_handle_get_summary (kmailhandle);
 	handle_ft = kolab_mail_summary_get_uint_field (summary,
 	                                               KOLAB_MAIL_SUMMARY_UINT_FIELD_FOLDER_TYPE);
@@ -2299,7 +2299,7 @@ kolab_mail_access_store_handle (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	                                    
+
 	/* handle is now no longer 'complete', Kolab_conv_mail part
 	 * and summary have been ripped out and stored in SideCache/ImapClient
 	 * and InfoDb, respectively
@@ -2337,7 +2337,7 @@ kolab_mail_access_store_handle (KolabMailAccess *self,
  *   <listitem>Handle precondition: none</listitem>
  *   <listitem>Handle postcondition: complete</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: TRUE on success,
  *          FALSE if reading or converting the PIM data failed (with @err set)
  */
@@ -2360,7 +2360,7 @@ kolab_mail_access_retrieve_handle (KolabMailAccess *self,
 	const gchar *uid = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (KOLAB_IS_MAIL_HANDLE (kmailhandle));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -2395,7 +2395,7 @@ kolab_mail_access_retrieve_handle (KolabMailAccess *self,
 
 	summary = kolab_mail_handle_get_summary_nonconst (local_handle);
 	uid = kolab_mail_handle_get_uid (local_handle);
-	
+
 	/* check cache location */
 	location = kolab_mail_handle_get_cache_location (local_handle);
 
@@ -2405,7 +2405,7 @@ kolab_mail_access_retrieve_handle (KolabMailAccess *self,
 	 */
 	if ((location == KOLAB_OBJECT_CACHE_LOCATION_NONE) &&
 	    kolab_mail_handle_is_complete (local_handle))
-			return TRUE;
+		return TRUE;
 
 	/* if the handle is cached in the SideCache, we'll retrieve
 	 * this local data (no ImapClient lookup in this case, though
@@ -2454,12 +2454,12 @@ kolab_mail_access_retrieve_handle (KolabMailAccess *self,
 		if (! ok) {
 			g_propagate_error (err, tmp_err);
 			return FALSE;
-		}		
+		}
 		g_debug ("%s: UID (%s) data retrieved from imap client",
 		         __func__, uid);
-		return TRUE;		
+		return TRUE;
 	}
-	
+
 	/* more cache location bit checks could go here */
 
 	g_assert_not_reached (); /* TODO better handling of location bits here */
@@ -2491,7 +2491,7 @@ kolab_mail_access_retrieve_handle (KolabMailAccess *self,
  *   <listitem>Handle precondition: none</listitem>
  *   <listitem>Handle postcondition: invalid</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: TRUE on success,
  *          FALSE if offline deletion failed (with @err set)
  */
@@ -2507,7 +2507,7 @@ kolab_mail_access_delete_handle (KolabMailAccess *self,
 	gchar *foldername = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (KOLAB_IS_MAIL_HANDLE (kmailhandle));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -2551,7 +2551,7 @@ kolab_mail_access_delete_handle (KolabMailAccess *self,
 	handles_tbl = g_hash_table_lookup (priv->handles, foldername);
 	if (handles_tbl != NULL)
 		g_hash_table_remove (handles_tbl, uid);
-	
+
 	/* TODO should the deleted UID be recorded in changed_uids_lst? */
 
 	g_free (uid);
@@ -2575,7 +2575,7 @@ kolab_mail_access_delete_handle (KolabMailAccess *self,
  *   <listitem>Handle precondition: none</listitem>
  *   <listitem>Handle postcondition: invalid</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: TRUE on success,
  *          FALSE if no PIM object found for @uid or
  *                if offline deletion failed (each with @err set)
@@ -2593,7 +2593,7 @@ kolab_mail_access_delete_by_uid (KolabMailAccess *self,
 	gchar *foldername = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (uid != NULL);
 	g_assert (sourcename != NULL);
@@ -2609,7 +2609,7 @@ kolab_mail_access_delete_by_uid (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	/* lookup mail handle in local databases */
 	local_handle = kolab_mail_access_local_handle_get_by_uid (self,
 	                                                          uid,
@@ -2665,7 +2665,7 @@ kolab_mail_access_delete_by_uid (KolabMailAccess *self,
  * Any source creation or deletion will also invalidate the list returned.
  * Get a fresh list each time you need to operate on one, unless you can be
  * sure there has been no change.
- * 
+ *
  * Free the list via a call to kolab_util_glib_glist_free() when no longer
  * needed.
  *
@@ -2676,7 +2676,7 @@ kolab_mail_access_delete_by_uid (KolabMailAccess *self,
  *
  * Returns: A list of source name strings on success,
  *          NULL otherwise (with @err set)
- * 
+ *
  */
 GList*
 kolab_mail_access_query_sources (KolabMailAccess *self,
@@ -2689,7 +2689,7 @@ kolab_mail_access_query_sources (KolabMailAccess *self,
 	gchar *tmp_sn = NULL;
 	const gchar *tmp_fn = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -2702,7 +2702,7 @@ kolab_mail_access_query_sources (KolabMailAccess *self,
 	if (tmp_err != NULL) {
 		kolab_util_glib_glist_free (folders);
 		g_propagate_error (err, tmp_err);
-		return NULL;		
+		return NULL;
 	}
 
 	folders_ptr = folders;
@@ -2726,15 +2726,15 @@ kolab_mail_access_query_sources (KolabMailAccess *self,
 			           __func__, tmp_fn);
 			goto folder_skip;
 		}
-		
-		sources = g_list_prepend (sources, tmp_sn);	
+
+		sources = g_list_prepend (sources, tmp_sn);
 
 	folder_skip:
 		folders_ptr = g_list_next (folders_ptr);
 	}
 
 	kolab_util_glib_glist_free (folders);
-	
+
 	return sources;
 }
 
@@ -2748,14 +2748,14 @@ kolab_mail_access_query_sources (KolabMailAccess *self,
  * needs to be created using this function prior to storing a #KolabMailHandle
  * into this source. If the @sourcename supplied already exists, the function
  * simply returns successfully.
- * 
+ *
  * If #KolabMailAccess is in online operational mode, the source gets created on
  * the Kolab server right away. If that fails or if #KolabMailAccess is in offline
  * operational mode, the source gets created in the local cache only and is
  * synchronized with the server at the next synchronization point. If the source
  * was created locally only, you can nonetheless store #KolabMailHandle objects
  * in it.
- * 
+ *
  * Returns: TRUE on success,
  *          FALSE if offline creation failed (with @err set)
  */
@@ -2769,7 +2769,7 @@ kolab_mail_access_create_source (KolabMailAccess *self,
 	gboolean exists = FALSE;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (sourcename != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -2797,7 +2797,7 @@ kolab_mail_access_create_source (KolabMailAccess *self,
 
 	if (exists) {
 		g_free (foldername);
-		return TRUE;		
+		return TRUE;
 	}
 
 	/* create folder */
@@ -2810,7 +2810,7 @@ kolab_mail_access_create_source (KolabMailAccess *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	return TRUE;
 }
 
@@ -2827,7 +2827,7 @@ kolab_mail_access_create_source (KolabMailAccess *self,
  * CAUTION: Deleting a source means deleting all PIM data within it!
  * A deletion transaction which has been triggered successfully CANNOT be
  * cancelled!
- * 
+ *
  * If #KolabMailAccess is in online operational mode, the source gets deleted on
  * the Kolab server right away. If that fails or if #KolabMailAccess is in offline
  * operational mode, the source gets marked for deletion in the local cache
@@ -2836,7 +2836,7 @@ kolab_mail_access_create_source (KolabMailAccess *self,
  * operational mode. At the next synchronization point, the source will be
  * deleted from the server. There is presently no way of aborting this
  * procedure, once it has been started.
- * 
+ *
  * Returns: TRUE on success,
  *          FALSE if the @sourcename supplied does not exist or
  *                if offline deletion failed (both with @err set)
@@ -2851,7 +2851,7 @@ kolab_mail_access_delete_source (KolabMailAccess *self,
 	gboolean exists = FALSE;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (sourcename != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -2879,7 +2879,7 @@ kolab_mail_access_delete_source (KolabMailAccess *self,
 
 	if (! exists) {
 		g_free (foldername);
-		return TRUE;		
+		return TRUE;
 	}
 
 	/* delete folder */
@@ -2906,7 +2906,7 @@ kolab_mail_access_source_fbtrigger_needed (KolabMailAccess *self,
 	KolabFolderTypeID folder_type = KOLAB_FOLDER_TYPE_INVAL;
 	gchar *foldername = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_ACCESS (self));
 	g_assert (sourcename != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -2917,7 +2917,7 @@ kolab_mail_access_source_fbtrigger_needed (KolabMailAccess *self,
 	/* do not try to trigger if in offline mode */
 	if (priv->state->opmode <= KOLAB_MAIL_ACCESS_OPMODE_OFFLINE)
 		return FALSE;
-	
+
 	/* map Evo sourcename to Kolab foldername */
 	foldername = kolab_util_backend_foldername_new_from_sourcename (sourcename,
 	                                                                &tmp_err);
diff --git a/src/libekolab/kolab-mail-handle.c b/src/libekolab/kolab-mail-handle.c
index 32adbc9..863b2e0 100644
--- a/src/libekolab/kolab-mail-handle.c
+++ b/src/libekolab/kolab-mail-handle.c
@@ -12,12 +12,12 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
@@ -87,12 +87,12 @@ kolab_mail_handle_dispose (GObject *object)
 		g_object_unref (priv->ecalcomp);
 		priv->ecalcomp = NULL;
 	}
-	
+
 	if (priv->timezone != NULL) {
 		g_object_unref (priv->timezone);
 		priv->timezone = NULL;
 	}
-		
+
 	if (priv->econtact != NULL) {
 		g_object_unref (priv->econtact);
 		priv->econtact = NULL;
@@ -124,7 +124,7 @@ kolab_mail_handle_finalize (GObject *object)
 		g_free (priv->kolab_uid);
 	if (priv->foldername != NULL)
 		g_free (priv->foldername);
-	
+
 	G_OBJECT_CLASS (kolab_mail_handle_parent_class)->finalize (object);
 }
 
@@ -153,7 +153,7 @@ kolab_mail_handle_check_complete (const KolabMailHandle *self,
 	KolabMailHandlePrivate *priv = NULL;
 	guint folder_context = 0;
 	gboolean complete = FALSE;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -211,13 +211,13 @@ KolabMailHandle*
 kolab_mail_handle_new_shallow (const gchar *uid,
                                const gchar *foldername)
 {
-                                       
+
 	KolabMailHandle *self = NULL;
 	KolabMailHandlePrivate *priv = NULL;
 
 	g_assert (uid != NULL);
 	/* foldername may be NULL */
-	
+
 	/* instantiate kolab mail handle */
 	self = KOLAB_MAIL_HANDLE (g_object_new (KOLAB_TYPE_MAIL_HANDLE, NULL));
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -250,7 +250,7 @@ kolab_mail_handle_new_from_kconvmail (Kolab_conv_mail *kconvmail,
 	context = kolab_util_folder_type_map_to_context_id (folder_type);
 	g_assert ((context >= KOLAB_FOLDER_TYPE_EVENT) &&
 	          (context < KOLAB_FOLDER_LAST_TYPE));
-	
+
 	/* create handle object */
 	self = kolab_mail_handle_new_shallow (uid, foldername);
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -274,7 +274,7 @@ kolab_mail_handle_new_from_kconvmail (Kolab_conv_mail *kconvmail,
 	kolab_mail_summary_set_uint_field (priv->summary,
 	                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_FOLDER_TYPE,
 	                                   folder_type);
-	
+
 	return self;
 }
 
@@ -293,7 +293,7 @@ kolab_mail_handle_new_from_handle (const KolabMailHandle *kmailhandle)
 	uid = kolab_mail_handle_get_uid (kmailhandle);
 	foldername = kolab_mail_handle_get_foldername (kmailhandle);
 	summary = kolab_mail_handle_get_summary (kmailhandle);
-	
+
 	/* create new handle object */
 	self = kolab_mail_handle_new_shallow (uid, foldername);
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -322,7 +322,7 @@ kolab_mail_handle_new_from_handle_with_kconvmail (const KolabMailHandle *kmailha
 		kconvmail_loc = kolab_util_kconv_kconvmail_clone (kconvmail);
 		kolab_mail_handle_set_kconvmail (self, kconvmail_loc);
 	}
-	
+
 	return self;
 }
 
@@ -362,35 +362,35 @@ kolab_mail_handle_convert_eds_to_kconvmail (KolabMailHandle *self,
 	calcomptz = g_new0 (ECalComponentWithTZ, 1);
 	calcomptz->maincomp = priv->ecalcomp;
 	calcomptz->timezone = priv->timezone;
-	
+
 	switch (folder_type) {
-		case KOLAB_FOLDER_TYPE_EVENT_DEFAULT:
-		case KOLAB_FOLDER_TYPE_EVENT: /* E_CAL_COMPONENT_EVENT */
-			g_debug ("%s: UID (%s) Folder (%s) converting type EVENT",
-			         __func__, priv->kolab_uid, priv->foldername);
-			kconvmail = kolabconv_eevent_to_kevent (calcomptz, &tmp_err);
-			break;
-		case KOLAB_FOLDER_TYPE_TASK_DEFAULT:
-		case KOLAB_FOLDER_TYPE_TASK:  /* E_CAL_COMPONENT_TODO */
-			g_debug ("%s: UID (%s) Folder (%s) converting type TASK",
-			         __func__, priv->kolab_uid, priv->foldername);
-			kconvmail = kolabconv_etask_to_ktask (calcomptz, &tmp_err);
-			break;
-		case KOLAB_FOLDER_TYPE_NOTE_DEFAULT:
-		case KOLAB_FOLDER_TYPE_NOTE:  /* E_CAL_COMPONENT_JOURNAL */
-			g_debug ("%s: UID (%s) Folder (%s) converting type NOTE",
-			         __func__, priv->kolab_uid, priv->foldername);
-			kconvmail = kolabconv_enote_to_knote (calcomptz, &tmp_err);
-			break;
-		case KOLAB_FOLDER_TYPE_CONTACT_DEFAULT:
-		case KOLAB_FOLDER_TYPE_CONTACT:
-			g_debug ("%s: UID (%s) Folder (%s) converting type CONTACT",
-			         __func__, priv->kolab_uid, priv->foldername);
-			kconvmail = kolabconv_econtact_to_kcontact (priv->econtact, &tmp_err);
-			break;
+	case KOLAB_FOLDER_TYPE_EVENT_DEFAULT:
+	case KOLAB_FOLDER_TYPE_EVENT: /* E_CAL_COMPONENT_EVENT */
+		g_debug ("%s: UID (%s) Folder (%s) converting type EVENT",
+		         __func__, priv->kolab_uid, priv->foldername);
+		kconvmail = kolabconv_eevent_to_kevent (calcomptz, &tmp_err);
+		break;
+	case KOLAB_FOLDER_TYPE_TASK_DEFAULT:
+	case KOLAB_FOLDER_TYPE_TASK:  /* E_CAL_COMPONENT_TODO */
+		g_debug ("%s: UID (%s) Folder (%s) converting type TASK",
+		         __func__, priv->kolab_uid, priv->foldername);
+		kconvmail = kolabconv_etask_to_ktask (calcomptz, &tmp_err);
+		break;
+	case KOLAB_FOLDER_TYPE_NOTE_DEFAULT:
+	case KOLAB_FOLDER_TYPE_NOTE:  /* E_CAL_COMPONENT_JOURNAL */
+		g_debug ("%s: UID (%s) Folder (%s) converting type NOTE",
+		         __func__, priv->kolab_uid, priv->foldername);
+		kconvmail = kolabconv_enote_to_knote (calcomptz, &tmp_err);
+		break;
+	case KOLAB_FOLDER_TYPE_CONTACT_DEFAULT:
+	case KOLAB_FOLDER_TYPE_CONTACT:
+		g_debug ("%s: UID (%s) Folder (%s) converting type CONTACT",
+		         __func__, priv->kolab_uid, priv->foldername);
+		kconvmail = kolabconv_econtact_to_kcontact (priv->econtact, &tmp_err);
+		break;
 		/* FIXME take care of JOURNAL type which we don't support */
-		default:
-			g_assert_not_reached ();
+	default:
+		g_assert_not_reached ();
 	}
 
 	calcomptz->maincomp = NULL;
@@ -416,12 +416,12 @@ kolab_mail_handle_convert_eds_to_kconvmail (KolabMailHandle *self,
 	 * later on when the handle is passed to ImapClient for store operation.
 	 * Passing the handle to SideCache for store will resect only in
 	 * offline operational mode (when online, ImapClient needs kconvmail
-         * as well, so SideCache must not resect it)
+	 * as well, so SideCache must not resect it)
 	 */
 	if (priv->kconvmail != NULL)
 		kolabconv_free_kmail (priv->kconvmail);
 	priv->kconvmail = kconvmail;
-	
+
 	return TRUE;
 }
 
@@ -438,14 +438,14 @@ kolab_mail_handle_convert_kconvmail_to_eds (KolabMailHandle *self,
 	const gchar *component_uid = NULL;
 	gchar *contact_uid = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
 
 	g_assert (priv->kconvmail != NULL);
-	
+
 	folder_type = kolab_mail_summary_get_uint_field (priv->summary,
 	                                                 KOLAB_MAIL_SUMMARY_UINT_FIELD_FOLDER_TYPE);
 	context = kolab_mail_summary_get_uint_field (priv->summary,
@@ -453,52 +453,52 @@ kolab_mail_handle_convert_kconvmail_to_eds (KolabMailHandle *self,
 
 	g_debug ("%s: UID (%s) Folder (%s) converting from Kolab, folder type/context (%i)/(%i)",
 	         __func__, priv->kolab_uid, priv->foldername, folder_type, context);
-	
+
 	/* do Kolab->EDS data conversion */
 	switch (folder_type) {
-		case KOLAB_FOLDER_TYPE_EVENT_DEFAULT:
-		case KOLAB_FOLDER_TYPE_EVENT: /* E_CAL_COMPONENT_EVENT */
-			g_debug ("%s: UID (%s) Folder (%s) converting from type EVENT",
-			         __func__, priv->kolab_uid, priv->foldername);
-			calcomptz = kolabconv_kevent_to_eevent (priv->kconvmail,
-			                                        &tmp_err);
-			break;
-		case KOLAB_FOLDER_TYPE_TASK_DEFAULT:
-		case KOLAB_FOLDER_TYPE_TASK:  /* E_CAL_COMPONENT_TODO */
-			g_debug ("%s: UID (%s) Folder (%s) converting from type TASK",
-			         __func__, priv->kolab_uid, priv->foldername);
-			calcomptz = kolabconv_ktask_to_etask (priv->kconvmail,
-			                                      &tmp_err);
-			break;
-		case KOLAB_FOLDER_TYPE_NOTE_DEFAULT:
-		case KOLAB_FOLDER_TYPE_NOTE:  /* E_CAL_COMPONENT_JOURNAL */
-			g_debug ("%s: UID (%s) Folder (%s) converting from type NOTE",
-			         __func__, priv->kolab_uid, priv->foldername);
-			calcomptz = kolabconv_knote_to_enote (priv->kconvmail,
-			                                      &tmp_err);
-			break;
-		case KOLAB_FOLDER_TYPE_CONTACT_DEFAULT:
-		case KOLAB_FOLDER_TYPE_CONTACT:
-			g_debug ("%s: UID (%s) Folder (%s) converting from type CONTACT",
-			         __func__, priv->kolab_uid, priv->foldername);
-			econtact = kolabconv_kcontact_to_econtact (priv->kconvmail,
-			                                           &tmp_err);
-			break;
-		case KOLAB_FOLDER_TYPE_JOURNAL_DEFAULT:
-		case KOLAB_FOLDER_TYPE_JOURNAL:
-			g_set_error (err,
-			             KOLAB_BACKEND_ERROR,
-			             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
-			             "%s: UID (%s) Folder (%s) JOURNAL data type not supported",
-			             __func__, priv->kolab_uid, priv->foldername);
-			return FALSE;
-		default:
-			g_set_error (err,
-			             KOLAB_BACKEND_ERROR,
-			             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
-			             "%s: UID (%s) Folder (%s) unknown data type, not supported",
-			             __func__, priv->kolab_uid, priv->foldername);
-			return FALSE;
+	case KOLAB_FOLDER_TYPE_EVENT_DEFAULT:
+	case KOLAB_FOLDER_TYPE_EVENT: /* E_CAL_COMPONENT_EVENT */
+		g_debug ("%s: UID (%s) Folder (%s) converting from type EVENT",
+		         __func__, priv->kolab_uid, priv->foldername);
+		calcomptz = kolabconv_kevent_to_eevent (priv->kconvmail,
+		                                        &tmp_err);
+		break;
+	case KOLAB_FOLDER_TYPE_TASK_DEFAULT:
+	case KOLAB_FOLDER_TYPE_TASK:  /* E_CAL_COMPONENT_TODO */
+		g_debug ("%s: UID (%s) Folder (%s) converting from type TASK",
+		         __func__, priv->kolab_uid, priv->foldername);
+		calcomptz = kolabconv_ktask_to_etask (priv->kconvmail,
+		                                      &tmp_err);
+		break;
+	case KOLAB_FOLDER_TYPE_NOTE_DEFAULT:
+	case KOLAB_FOLDER_TYPE_NOTE:  /* E_CAL_COMPONENT_JOURNAL */
+		g_debug ("%s: UID (%s) Folder (%s) converting from type NOTE",
+		         __func__, priv->kolab_uid, priv->foldername);
+		calcomptz = kolabconv_knote_to_enote (priv->kconvmail,
+		                                      &tmp_err);
+		break;
+	case KOLAB_FOLDER_TYPE_CONTACT_DEFAULT:
+	case KOLAB_FOLDER_TYPE_CONTACT:
+		g_debug ("%s: UID (%s) Folder (%s) converting from type CONTACT",
+		         __func__, priv->kolab_uid, priv->foldername);
+		econtact = kolabconv_kcontact_to_econtact (priv->kconvmail,
+		                                           &tmp_err);
+		break;
+	case KOLAB_FOLDER_TYPE_JOURNAL_DEFAULT:
+	case KOLAB_FOLDER_TYPE_JOURNAL:
+		g_set_error (err,
+		             KOLAB_BACKEND_ERROR,
+		             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
+		             "%s: UID (%s) Folder (%s) JOURNAL data type not supported",
+		             __func__, priv->kolab_uid, priv->foldername);
+		return FALSE;
+	default:
+		g_set_error (err,
+		             KOLAB_BACKEND_ERROR,
+		             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
+		             "%s: UID (%s) Folder (%s) unknown data type, not supported",
+		             __func__, priv->kolab_uid, priv->foldername);
+		return FALSE;
 	}
 
 	/* enforce GError conformance */
@@ -516,73 +516,73 @@ kolab_mail_handle_convert_kconvmail_to_eds (KolabMailHandle *self,
 			           __func__, priv->kolab_uid, priv->foldername);
 		}
 		g_propagate_error (err, tmp_err);
-		return FALSE;		
+		return FALSE;
 	}
 
 	/* sanity checking */
 	switch (context) {
-		case KOLAB_FOLDER_CONTEXT_CALENDAR:
-			/* ECalComponentWithTZ sanity checks */
-			if (calcomptz == NULL) {
-				g_set_error (err,
-					     KOLAB_BACKEND_ERROR,
-					     KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
-					     "%s: UID (%s) Folder (%s) conversion from Kolab calendar type failed",
-					     __func__, priv->kolab_uid, priv->foldername);
-				return FALSE;
-			}
-			if (calcomptz->maincomp == NULL) {
-				g_set_error (err,
-					     KOLAB_BACKEND_ERROR,
-					     KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
-					     "%s: UID (%s) Folder (%s) got ECalComponentWithTZ with NULL maincomp member",
-					     __func__, priv->kolab_uid, priv->foldername);
-				return FALSE;
-			}
-			e_cal_component_get_uid (calcomptz->maincomp, &component_uid);
-			if (g_strcmp0 (priv->kolab_uid, component_uid) != 0) {
-				g_debug ("%s: Kolab UID (subject/xml): (%s)/(%s)",
-					 __func__, priv->kolab_uid, component_uid);
-				kolabconv_free_ecalendar (calcomptz);
-				g_set_error (err,
-					     KOLAB_BACKEND_ERROR,
-					     KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
-					     "%s: UID (%s) Folder (%s) invalid Kolab mail (UID in subject does not match UID in data part)",
-					     __func__, priv->kolab_uid, priv->foldername);
-				return FALSE;
-			}
-			/* KolabMailSummary */
-			summary = kolab_mail_summary_new_from_ecalcomponent (calcomptz->maincomp);
-			break;
-		case KOLAB_FOLDER_CONTEXT_CONTACT:
-			/* EContact sanity checks */
-			if (econtact == NULL) {
-				g_set_error (err,
-					     KOLAB_BACKEND_ERROR,
-					     KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
-					     "%s: UID (%s) Folder (%s) conversion from Kolab contact type failed",
-					     __func__, priv->kolab_uid, priv->foldername);
-				return FALSE;
-			}
-			contact_uid = e_contact_get (econtact, E_CONTACT_UID);
-			if (g_strcmp0 (priv->kolab_uid, contact_uid) != 0) {
-				g_debug ("%s: Kolab UID (subject/xml): (%s)/(%s)",
-					 __func__, priv->kolab_uid, contact_uid);
-				g_free (contact_uid);
-				kolabconv_free_econtact (econtact);
-				g_set_error (err,
-					     KOLAB_BACKEND_ERROR,
-					     KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
-					     "%s: UID (%s) Folder (%s) invalid Kolab mail (UID in subject does not match UID in data part)",
-					     __func__, priv->kolab_uid, priv->foldername);
-				return FALSE;
-			}
+	case KOLAB_FOLDER_CONTEXT_CALENDAR:
+		/* ECalComponentWithTZ sanity checks */
+		if (calcomptz == NULL) {
+			g_set_error (err,
+			             KOLAB_BACKEND_ERROR,
+			             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
+			             "%s: UID (%s) Folder (%s) conversion from Kolab calendar type failed",
+			             __func__, priv->kolab_uid, priv->foldername);
+			return FALSE;
+		}
+		if (calcomptz->maincomp == NULL) {
+			g_set_error (err,
+			             KOLAB_BACKEND_ERROR,
+			             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
+			             "%s: UID (%s) Folder (%s) got ECalComponentWithTZ with NULL maincomp member",
+			             __func__, priv->kolab_uid, priv->foldername);
+			return FALSE;
+		}
+		e_cal_component_get_uid (calcomptz->maincomp, &component_uid);
+		if (g_strcmp0 (priv->kolab_uid, component_uid) != 0) {
+			g_debug ("%s: Kolab UID (subject/xml): (%s)/(%s)",
+			         __func__, priv->kolab_uid, component_uid);
+			kolabconv_free_ecalendar (calcomptz);
+			g_set_error (err,
+			             KOLAB_BACKEND_ERROR,
+			             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
+			             "%s: UID (%s) Folder (%s) invalid Kolab mail (UID in subject does not match UID in data part)",
+			             __func__, priv->kolab_uid, priv->foldername);
+			return FALSE;
+		}
+		/* KolabMailSummary */
+		summary = kolab_mail_summary_new_from_ecalcomponent (calcomptz->maincomp);
+		break;
+	case KOLAB_FOLDER_CONTEXT_CONTACT:
+		/* EContact sanity checks */
+		if (econtact == NULL) {
+			g_set_error (err,
+			             KOLAB_BACKEND_ERROR,
+			             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
+			             "%s: UID (%s) Folder (%s) conversion from Kolab contact type failed",
+			             __func__, priv->kolab_uid, priv->foldername);
+			return FALSE;
+		}
+		contact_uid = e_contact_get (econtact, E_CONTACT_UID);
+		if (g_strcmp0 (priv->kolab_uid, contact_uid) != 0) {
+			g_debug ("%s: Kolab UID (subject/xml): (%s)/(%s)",
+			         __func__, priv->kolab_uid, contact_uid);
 			g_free (contact_uid);
-			/* KolabMailSummary */
-			summary = kolab_mail_summary_new_from_econtact (econtact);
-			break;
-		default:
-			g_assert_not_reached ();
+			kolabconv_free_econtact (econtact);
+			g_set_error (err,
+			             KOLAB_BACKEND_ERROR,
+			             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
+			             "%s: UID (%s) Folder (%s) invalid Kolab mail (UID in subject does not match UID in data part)",
+			             __func__, priv->kolab_uid, priv->foldername);
+			return FALSE;
+		}
+		g_free (contact_uid);
+		/* KolabMailSummary */
+		summary = kolab_mail_summary_new_from_econtact (econtact);
+		break;
+	default:
+		g_assert_not_reached ();
 	}
 
 	/* set the summary bits we know here */
@@ -605,30 +605,30 @@ kolab_mail_handle_convert_kconvmail_to_eds (KolabMailHandle *self,
 
 	/* attach handle data */
 	switch (context) {
-		case KOLAB_FOLDER_CONTEXT_CALENDAR:
-			if (priv->ecalcomp != NULL)
-				g_object_unref (priv->ecalcomp);
-			if (priv->timezone != NULL)
-				g_object_unref (priv->timezone);
-			priv->ecalcomp = calcomptz->maincomp;
-			priv->timezone = calcomptz->timezone;
-			calcomptz->maincomp = NULL;
-			calcomptz->timezone = NULL;
-			g_free (calcomptz); /* free struct only */
-			break;
-		case KOLAB_FOLDER_CONTEXT_CONTACT:
-			if (priv->econtact)
-				g_object_unref (priv->econtact);
-			priv->econtact = econtact;
-			break;
-		default:
-			g_assert_not_reached ();
+	case KOLAB_FOLDER_CONTEXT_CALENDAR:
+		if (priv->ecalcomp != NULL)
+			g_object_unref (priv->ecalcomp);
+		if (priv->timezone != NULL)
+			g_object_unref (priv->timezone);
+		priv->ecalcomp = calcomptz->maincomp;
+		priv->timezone = calcomptz->timezone;
+		calcomptz->maincomp = NULL;
+		calcomptz->timezone = NULL;
+		g_free (calcomptz); /* free struct only */
+		break;
+	case KOLAB_FOLDER_CONTEXT_CONTACT:
+		if (priv->econtact)
+			g_object_unref (priv->econtact);
+		priv->econtact = econtact;
+		break;
+	default:
+		g_assert_not_reached ();
 	}
 
 	/* once the conversion is completed, we only keep EDS payload data */
 	kolabconv_free_kmail (priv->kconvmail);
 	priv->kconvmail = NULL;
-	
+
 	return TRUE;
 }
 
@@ -662,7 +662,7 @@ kolab_mail_handle_get_kconvmail (const KolabMailHandle *self)
 	return priv->kconvmail;
 }
 
-void 
+void
 kolab_mail_handle_set_kconvmail (KolabMailHandle *self,
                                  Kolab_conv_mail *kconvmail)
 {
@@ -717,7 +717,7 @@ kolab_mail_handle_kconvmail_is_equal (KolabMailHandle *self,
 	gchar *s_checksum = NULL;
 	gchar *o_checksum = NULL;
 	gboolean is_eq = TRUE;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 	g_assert (KOLAB_IS_MAIL_HANDLE (other));
 
@@ -748,7 +748,7 @@ kolab_mail_handle_set_uid (KolabMailHandle *self,
                            const gchar *uid)
 {
 	KolabMailHandlePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 	g_assert (uid != NULL);
 
@@ -774,41 +774,41 @@ kolab_mail_handle_set_uid_full (KolabMailHandle *self,
 	KolabFolderContextID context = KOLAB_FOLDER_CONTEXT_INVAL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 	g_assert (uid != NULL);
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
-	
+
 	context = kolab_mail_summary_get_uint_field (priv->summary,
 	                                             KOLAB_MAIL_SUMMARY_UINT_FIELD_FOLDER_CONTEXT);
 	switch (context) {
-		case KOLAB_FOLDER_CONTEXT_CALENDAR:
-			if ((priv->ecalcomp == NULL) && (priv->kconvmail != NULL)) {
-				ok = kolab_mail_handle_convert_kconvmail_to_eds (self,
-				                                                 &tmp_err);
-				if (! ok) {
-					g_propagate_error (err, tmp_err);
-					return FALSE;
-				}
+	case KOLAB_FOLDER_CONTEXT_CALENDAR:
+		if ((priv->ecalcomp == NULL) && (priv->kconvmail != NULL)) {
+			ok = kolab_mail_handle_convert_kconvmail_to_eds (self,
+			                                                 &tmp_err);
+			if (! ok) {
+				g_propagate_error (err, tmp_err);
+				return FALSE;
 			}
-			if (priv->ecalcomp != NULL)
-				e_cal_component_set_uid (priv->ecalcomp, uid);
-			break;
-		case KOLAB_FOLDER_CONTEXT_CONTACT:
-			if ((priv->econtact == NULL) && (priv->kconvmail != NULL)) {
-				ok = kolab_mail_handle_convert_kconvmail_to_eds (self,
-				                                                 &tmp_err);
-				if (! ok) {
-					g_propagate_error (err, tmp_err);
-					return FALSE;
-				}
+		}
+		if (priv->ecalcomp != NULL)
+			e_cal_component_set_uid (priv->ecalcomp, uid);
+		break;
+	case KOLAB_FOLDER_CONTEXT_CONTACT:
+		if ((priv->econtact == NULL) && (priv->kconvmail != NULL)) {
+			ok = kolab_mail_handle_convert_kconvmail_to_eds (self,
+			                                                 &tmp_err);
+			if (! ok) {
+				g_propagate_error (err, tmp_err);
+				return FALSE;
 			}
-			if (priv->econtact != NULL)
-				e_contact_set (priv->econtact, E_CONTACT_UID, uid);
-			break;
-		default:
-			{ /* nop */ }
+		}
+		if (priv->econtact != NULL)
+			e_contact_set (priv->econtact, E_CONTACT_UID, uid);
+		break;
+	default:
+		{ /* nop */ }
 	}
 
 	kolab_mail_handle_set_uid (self, uid);
@@ -820,7 +820,7 @@ kolab_mail_handle_set_foldername (KolabMailHandle *self,
                                   const gchar *foldername)
 {
 	KolabMailHandlePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 	g_assert (foldername != NULL);
 
@@ -835,7 +835,7 @@ const KolabMailSummary*
 kolab_mail_handle_get_summary (const KolabMailHandle *self)
 {
 	KolabMailHandlePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -847,7 +847,7 @@ KolabMailSummary*
 kolab_mail_handle_get_summary_nonconst (const KolabMailHandle *self)
 {
 	KolabMailHandlePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -861,9 +861,9 @@ kolab_mail_handle_set_summary (KolabMailHandle *self,
                                GError **err)
 {
 	/* we take ownership of *summary here */
-	
+
 	KolabMailHandlePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 	/* summary may be NULL */
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -880,7 +880,7 @@ kolab_mail_handle_set_summary (KolabMailHandle *self,
 			return FALSE;
 		}
 	}
-	
+
 	if (priv->summary)
 		kolab_mail_summary_free (priv->summary);
 
@@ -908,12 +908,12 @@ kolab_mail_handle_set_summary (KolabMailHandle *self,
  * This sets the %KOLAB_FOLDER_CONTEXT_CALENDAR context on the handle, which means
  * that it can be passed to a #KolabMailAccess only if the latter is configured
  * with the same context.
- * 
+ *
  * <itemizedlist>
  *   <listitem>Handle precondition: none</listitem>
  *   <listitem>Handle postcondition: complete, %KOLAB_FOLDER_CONTEXT_CALENDAR</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: a #KolabMailHandle instance
  */
 KolabMailHandle*
@@ -931,17 +931,17 @@ kolab_mail_handle_new_from_ecalcomponent (ECalComponent *ecalcomp,
 
 	vtype = e_cal_component_get_vtype (ecalcomp);
 	switch (vtype) {
-		case E_CAL_COMPONENT_EVENT:
-			folder_type = KOLAB_FOLDER_TYPE_EVENT;
-			break;
-		case E_CAL_COMPONENT_TODO:
-			folder_type = KOLAB_FOLDER_TYPE_TASK;
-			break;
-		case E_CAL_COMPONENT_JOURNAL:
-			folder_type = KOLAB_FOLDER_TYPE_NOTE;
-			break;
-		default:
-			g_assert_not_reached ();
+	case E_CAL_COMPONENT_EVENT:
+		folder_type = KOLAB_FOLDER_TYPE_EVENT;
+		break;
+	case E_CAL_COMPONENT_TODO:
+		folder_type = KOLAB_FOLDER_TYPE_TASK;
+		break;
+	case E_CAL_COMPONENT_JOURNAL:
+		folder_type = KOLAB_FOLDER_TYPE_NOTE;
+		break;
+	default:
+		g_assert_not_reached ();
 	}
 	context = kolab_util_folder_type_map_to_context_id (folder_type);
 	g_assert (context != KOLAB_FOLDER_CONTEXT_INVAL);
@@ -999,12 +999,12 @@ kolab_mail_handle_new_from_ecalcomponent (ECalComponent *ecalcomp,
  * This sets the %KOLAB_FOLDER_CONTEXT_CONTACT context on the handle, which means
  * that it can be passed to a #KolabMailAccess only if the latter is configured
  * with the same context.
- * 
+ *
  * <itemizedlist>
  *   <listitem>Handle precondition: none</listitem>
  *   <listitem>Handle postcondition: complete, %KOLAB_FOLDER_CONTEXT_CONTACT</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: a #KolabMailHandle instance
  */
 KolabMailHandle*
@@ -1028,7 +1028,7 @@ kolab_mail_handle_new_from_econtact (EContact *econtact)
 	/* set local members */
 	g_object_ref (econtact);
 	priv->econtact = econtact;
-	
+
 	/* kolab mail handle summary */
 	priv->summary = kolab_mail_summary_new_from_econtact (econtact);
 	kolab_mail_summary_set_char_field (priv->summary,
@@ -1069,7 +1069,7 @@ kolab_mail_handle_gdestroy (gpointer object)
  *   <listitem>Handle precondition: none</listitem>
  *   <listitem>Handle postcondition: none</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: TRUE if @self is complete,
  *	    FALSE otherwise
  */
@@ -1078,14 +1078,14 @@ kolab_mail_handle_is_complete (const KolabMailHandle *self)
 {
 	KolabMailHandlePrivate *priv = NULL;
 	gboolean complete = FALSE;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
 
 	if (priv->summary == NULL)
 		return FALSE;
-	
+
 	complete = kolab_mail_summary_get_bool_field (priv->summary,
 	                                              KOLAB_MAIL_SUMMARY_BOOL_FIELD_COMPLETE);
 	return complete;
@@ -1105,7 +1105,7 @@ kolab_mail_handle_is_complete (const KolabMailHandle *self)
  *   <listitem>Handle precondition: none</listitem>
  *   <listitem>Handle postcondition: none</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: the UID string for this #KolabMailHandle instance
  */
 const gchar*
@@ -1115,7 +1115,7 @@ kolab_mail_handle_get_uid (const KolabMailHandle *self)
 
 	KolabMailHandlePrivate *priv = NULL;
 	const gchar *s_uid = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -1166,7 +1166,7 @@ kolab_mail_handle_get_uid (const KolabMailHandle *self)
  *   <listitem>Handle precondition: none</listitem>
  *   <listitem>Handle postcondition: none</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: the IMAP folder name string for this
  *          #KolabMailHandle instance (may be NULL)
  */
@@ -1174,9 +1174,9 @@ const gchar*
 kolab_mail_handle_get_foldername (const KolabMailHandle *self)
 {
 	/* may return NULL */
-	
+
 	KolabMailHandlePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -1189,7 +1189,7 @@ kolab_mail_handle_get_cache_location (const KolabMailHandle *self)
 {
 	KolabMailHandlePrivate *priv = NULL;
 	KolabObjectCacheLocation location = KOLAB_OBJECT_CACHE_LOCATION_INVAL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -1211,7 +1211,7 @@ kolab_mail_handle_set_cache_location (KolabMailHandle *self,
 {
 	KolabMailHandlePrivate *priv = NULL;
 	KolabObjectCacheLocation cl = KOLAB_OBJECT_CACHE_LOCATION_NONE;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 	g_assert (location < KOLAB_OBJECT_CACHE_LOCATION_INVAL);
 
@@ -1242,7 +1242,7 @@ kolab_mail_handle_unset_cache_location (KolabMailHandle *self,
 {
 	KolabMailHandlePrivate *priv = NULL;
 	KolabObjectCacheLocation cl = KOLAB_OBJECT_CACHE_LOCATION_NONE;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 	g_assert ((location > KOLAB_OBJECT_CACHE_LOCATION_NONE) &&
 	          (location < KOLAB_OBJECT_CACHE_LOCATION_INVAL));
@@ -1296,19 +1296,19 @@ kolab_mail_handle_unset_cache_location (KolabMailHandle *self,
  * This requires the %KOLAB_FOLDER_CONTEXT_CALENDAR context be set on the handle.
  * The handle must be complete in order to retrieve an #ECalComponent from it.
  * If the handle is incomplete, the function returns NULL.
- * 
+ *
  * <itemizedlist>
  *   <listitem>Handle precondition: complete, %KOLAB_FOLDER_CONTEXT_CALENDAR</listitem>
  *   <listitem>Handle postcondition: none</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: a ref'd #ECalComponent instance, or NULL
  */
 ECalComponent*
 kolab_mail_handle_get_ecalcomponent (const KolabMailHandle *self)
 {
 	KolabMailHandlePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -1334,14 +1334,14 @@ kolab_mail_handle_get_ecalcomponent (const KolabMailHandle *self)
  *   <listitem>Handle precondition: none</listitem>
  *   <listitem>Handle postcondition: none</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: the timezone #ECalComponent, or NULL
  */
 ECalComponent*
 kolab_mail_handle_get_timezone (const KolabMailHandle *self)
 {
 	KolabMailHandlePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
@@ -1364,19 +1364,19 @@ kolab_mail_handle_get_timezone (const KolabMailHandle *self)
  * This requires the %KOLAB_FOLDER_CONTEXT_CONTACT context be set on the handle.
  * The handle must be complete in order to retrieve an #EContact from it.
  * If the handle is incomplete, the function returns NULL.
- * 
+ *
  * <itemizedlist>
  *   <listitem>Handle precondition: complete, %KOLAB_FOLDER_CONTEXT_CONTACT</listitem>
  *   <listitem>Handle postcondition: none</listitem>
  * </itemizedlist>
- * 
+ *
  * Returns: a new #EContact instance, or NULL
  */
 EContact*
 kolab_mail_handle_get_econtact (const KolabMailHandle *self)
 {
 	KolabMailHandlePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_HANDLE (self));
 
 	priv = KOLAB_MAIL_HANDLE_PRIVATE (self);
diff --git a/src/libekolab/kolab-mail-imap-client.c b/src/libekolab/kolab-mail-imap-client.c
index f8d997d..aecdc34 100644
--- a/src/libekolab/kolab-mail-imap-client.c
+++ b/src/libekolab/kolab-mail-imap-client.c
@@ -12,17 +12,17 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
  */
- 
+
 /*----------------------------------------------------------------------------*/
 
 #include <camel/camel-kolab-imapx-provider.h>
@@ -103,7 +103,7 @@ kolab_mail_imap_client_init (KolabMailImapClient *object)
 	KolabMailImapClientPrivate *priv = NULL;
 
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (object));
-	
+
 	self = object;
 	priv = KOLAB_MAIL_IMAP_CLIENT_PRIVATE (self);
 
@@ -190,7 +190,7 @@ kolab_mail_imap_client_camel_get_folder (KolabMailImapClient *self,
 	CamelFolder *folder = NULL;
 	CamelException *tmp_ex = NULL;
 	guint32 flags = 0; /* TODO check which flags to set */
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, NULL);
@@ -222,7 +222,7 @@ kolab_mail_imap_client_camel_get_folder (KolabMailImapClient *self,
 	}
 
 	camel_exception_free (tmp_ex);
-	
+
 	if (folder == NULL) {
 		g_set_error (err,
 		             KOLAB_CAMEL_ERROR,
@@ -375,7 +375,7 @@ kolab_mail_imap_client_camel_get_msg_imap_uid (KolabMailImapClient *self,
 	CamelMessageInfo *mi = NULL;
 	CamelException *tmp_ex = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (foldername != NULL);
 	g_assert (imap_uid != NULL);
@@ -396,7 +396,7 @@ kolab_mail_imap_client_camel_get_msg_imap_uid (KolabMailImapClient *self,
 
 	/* we need to check for a valid CamelMessageInfo in any case,
 	 * this cannot be done solely if kolab_uid != NULL (because it
-         * safeguards us against no-longer existing imap_uids)
+	 * safeguards us against no-longer existing imap_uids)
 	 */
 	mi = camel_folder_get_message_info (folder, imap_uid);
 	if (mi == NULL) {
@@ -413,7 +413,7 @@ kolab_mail_imap_client_camel_get_msg_imap_uid (KolabMailImapClient *self,
 			camel_folder_free_message_info (folder, mi);
 			camel_object_unref (folder);
 			g_warning ("%s: Kolab UID (%s) IMAP UID (%s) have message with NULL subject",
-			          __func__, kolab_uid, imap_uid);
+			           __func__, kolab_uid, imap_uid);
 			return NULL;
 		}
 		if (g_strcmp0 (subject, kolab_uid) != 0) {
@@ -424,9 +424,9 @@ kolab_mail_imap_client_camel_get_msg_imap_uid (KolabMailImapClient *self,
 			return NULL;
 		}
 	}
-	
+
 	camel_folder_free_message_info (folder, mi);
-	
+
 	tmp_ex = camel_exception_new ();
 
 	message = camel_folder_get_message (folder, imap_uid, tmp_ex);
@@ -435,8 +435,8 @@ kolab_mail_imap_client_camel_get_msg_imap_uid (KolabMailImapClient *self,
 			camel_object_unref (message);
 		camel_object_unref (folder);
 		kolab_gerror_propagate_from_camelexception (err,
-			                                    tmp_ex,
-			                                    KOLAB_CAMEL_ERROR);
+		                                            tmp_ex,
+		                                            KOLAB_CAMEL_ERROR);
 		return NULL;
 	}
 	camel_exception_free (tmp_ex);
@@ -444,7 +444,7 @@ kolab_mail_imap_client_camel_get_msg_imap_uid (KolabMailImapClient *self,
 
 	if (message == NULL) {
 		g_warning ("%s: IMAP UID (%s) NULL message in camel folder",
-		             __func__, imap_uid);
+		           __func__, imap_uid);
 		return NULL;
 	}
 
@@ -464,7 +464,7 @@ kolab_mail_imap_client_camel_get_msg_kolab_uid (KolabMailImapClient *self,
                                                 GError **err)
 {
 	KolabMailImapClientPrivate *priv = NULL;
-        CamelFolder *folder = NULL;
+	CamelFolder *folder = NULL;
 	CamelMimeMessage *message = NULL;
 	GPtrArray *imap_uids = NULL;
 	CamelException *tmp_ex = NULL;
@@ -532,7 +532,7 @@ kolab_mail_imap_client_camel_get_msg_kolab_uid (KolabMailImapClient *self,
 
 		if (message == NULL)
 			continue;
-		
+
 		msg_subject = camel_mime_message_get_subject (message);
 		if (msg_subject == NULL) {
 			camel_object_unref (message);
@@ -543,7 +543,7 @@ kolab_mail_imap_client_camel_get_msg_kolab_uid (KolabMailImapClient *self,
 		}
 		if (g_strcmp0 (msg_subject, kolab_uid) == 0)
 			break; /* message found */
-		
+
 		camel_object_unref (message);
 		message = NULL;
 	}
@@ -568,7 +568,7 @@ kolab_mail_imap_client_update_folder (KolabMailImapClient *self,
 	CamelException *tmp_ex = NULL;
 	GError *tmp_err = NULL;
 
-		g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
+	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -650,7 +650,7 @@ kolab_mail_imap_client_configure (KolabMailImapClient *self,
 	KolabMailImapClientPrivate *priv = NULL;
 	const gchar *tmp_str = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (ksettings));
 	g_assert (KOLAB_IS_MAIL_MIME_BUILDER (mimebuilder));
@@ -668,7 +668,7 @@ kolab_mail_imap_client_configure (KolabMailImapClient *self,
 	g_object_ref (mimebuilder);
 	priv->ksettings = ksettings;
 	priv->mimebuilder = mimebuilder;
-		
+
 	/* we store the context locally, all else we can/should get on-the-fly
 	 * from the settings handler
 	 */
@@ -690,9 +690,9 @@ kolab_mail_imap_client_configure (KolabMailImapClient *self,
 
 	/* create session object */
 	priv->session = camel_kolab_session_new ();
-	
+
 	/* set up session object directories (create if not existing) */
-	
+
 	tmp_str = kolab_settings_handler_get_char_field (priv->ksettings,
 	                                                 KOLAB_SETTINGS_HANDLER_CHAR_FIELD_CAMEL_DATA_DIR,
 	                                                 &tmp_err);
@@ -739,7 +739,7 @@ kolab_mail_imap_client_bringup (KolabMailImapClient *self,
 	priv = KOLAB_MAIL_IMAP_CLIENT_PRIVATE (self);
 
 	g_assert (priv->is_online == FALSE);
-	
+
 	if (priv->is_up == TRUE)
 		return TRUE;
 
@@ -749,7 +749,7 @@ kolab_mail_imap_client_bringup (KolabMailImapClient *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	/* create url string for session getter */
 	camel_url = camel_url_new (KOLAB_CAMELURL_DUMMY_URL, NULL);
 	camel_url_set_protocol (camel_url, KOLAB_CAMEL_PROVIDER_PROTOCOL);
@@ -769,7 +769,7 @@ kolab_mail_imap_client_bringup (KolabMailImapClient *self,
 		             "%s: need server name to be set",
 		             __func__);
 		return FALSE;
-		             
+
 	}
 	camel_url_set_host (camel_url, tmp_str);
 	tmp_str = kolab_settings_handler_get_char_field (priv->ksettings,
@@ -788,7 +788,7 @@ kolab_mail_imap_client_bringup (KolabMailImapClient *self,
 		             "%s: need user name to be set",
 		             __func__);
 		return FALSE;
-		             
+
 	}
 	camel_url_set_user (camel_url, tmp_str);
 	tlsvariant = kolab_settings_handler_get_uint_field (priv->ksettings,
@@ -800,25 +800,25 @@ kolab_mail_imap_client_bringup (KolabMailImapClient *self,
 		return FALSE;
 	}
 	switch (tlsvariant) {
-		case KOLAB_TLS_VARIANT_SSL:
-			variant_str = KOLAB_MAIL_IMAP_CLIENT_TLSVARIANT_SSL;
-			break;
-		case KOLAB_TLS_VARIANT_STARTTLS:
-			variant_str = KOLAB_MAIL_IMAP_CLIENT_TLSVARIANT_STARTTLS;
-			break;
-		default:
-			variant_str = KOLAB_MAIL_IMAP_CLIENT_TLSVARIANT_NONE;
+	case KOLAB_TLS_VARIANT_SSL:
+		variant_str = KOLAB_MAIL_IMAP_CLIENT_TLSVARIANT_SSL;
+		break;
+	case KOLAB_TLS_VARIANT_STARTTLS:
+		variant_str = KOLAB_MAIL_IMAP_CLIENT_TLSVARIANT_STARTTLS;
+		break;
+	default:
+		variant_str = KOLAB_MAIL_IMAP_CLIENT_TLSVARIANT_NONE;
 	}
 	camel_url_set_param (camel_url,
 	                     KOLAB_MAIL_IMAP_CLIENT_CAMELURL_PARAM_SSL,
 	                     variant_str);
-	
+
 	/* camel_url_string = camel_url_to_string (camel_url, CAMEL_URL_HIDE_ALL); */
 	camel_url_string = camel_url_to_string (camel_url, CAMEL_URL_HIDE_PASSWORD);
 	g_debug ("%s: CamelURL: (%s)", __func__, camel_url_string);
-	
+
 	/* bring up imapx object */
-	tmp_ex = camel_exception_new ();	
+	tmp_ex = camel_exception_new ();
 	service = camel_session_get_service (CAMEL_SESSION (priv->session),
 	                                     camel_url_string,
 	                                     CAMEL_PROVIDER_STORE,
@@ -886,7 +886,7 @@ kolab_mail_imap_client_bringup (KolabMailImapClient *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	priv->is_up = TRUE;
 	return TRUE;
 }
@@ -898,14 +898,14 @@ kolab_mail_imap_client_shutdown (KolabMailImapClient *self,
 	KolabMailImapClientPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
 	priv = KOLAB_MAIL_IMAP_CLIENT_PRIVATE (self);
 
 	g_assert (priv->is_online == FALSE);
-	
+
 	if (priv->is_up == FALSE)
 		return TRUE;
 
@@ -935,7 +935,7 @@ kolab_mail_imap_client_go_online (KolabMailImapClient *self,
 	const gchar *tmp_str = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1011,7 +1011,7 @@ kolab_mail_imap_client_go_offline (KolabMailImapClient *self,
 	KolabMailImapClientPrivate *priv = NULL;
 	CamelException *tmp_ex = NULL;
 	gboolean ok = FALSE;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1032,7 +1032,7 @@ kolab_mail_imap_client_go_offline (KolabMailImapClient *self,
 
 	/* disconnect the camel service */
 	tmp_ex = camel_exception_new ();
-	
+
 	camel_offline_store_prepare_for_offline (CAMEL_OFFLINE_STORE (priv->store),
 	                                         tmp_ex);
 	if (camel_exception_is_set (tmp_ex)) {
@@ -1051,7 +1051,7 @@ kolab_mail_imap_client_go_offline (KolabMailImapClient *self,
 	 *      to avoid lockups here if the server won't answer
 	 *      properly
 	 */
-	
+
 	/* issue LOGOUT message so we can get a BYE from server */
 	kolab_imapx_store_logout_sync (priv->store);
 
@@ -1075,7 +1075,7 @@ kolab_mail_imap_client_go_offline (KolabMailImapClient *self,
 	camel_session_set_online (CAMEL_SESSION (priv->session), FALSE);
 
 	g_debug ("KolabMailImapClient: changed state: offline operation");
-	
+
 	priv->is_online = FALSE;
 	return TRUE;
 }
@@ -1092,7 +1092,7 @@ kolab_mail_imap_client_query_foldernames (KolabMailImapClient *self,
 	GList *folder_list = NULL;
 	guint32 flags = 0;
 	CamelException *tmp_ex = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, NULL);
 
@@ -1133,7 +1133,7 @@ kolab_mail_imap_client_get_folder_type (KolabMailImapClient *self,
 	KolabMailImapClientPrivate *priv = NULL;
 	KolabFolderTypeID foldertype = KOLAB_FOLDER_TYPE_INVAL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, KOLAB_FOLDER_TYPE_INVAL);
@@ -1155,7 +1155,7 @@ kolab_mail_imap_client_get_folder_type (KolabMailImapClient *self,
 		             __func__, foldername);
 		return KOLAB_FOLDER_TYPE_INVAL;
 	}
-	
+
 	return foldertype;
 }
 
@@ -1168,7 +1168,7 @@ kolab_mail_imap_client_get_folder_uidvalidity (KolabMailImapClient *self,
 	CamelFolder *folder = NULL;
 	guint64 uidvalidity = 0;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, KOLAB_FOLDER_TYPE_INVAL);
@@ -1211,7 +1211,7 @@ kolab_mail_imap_client_query_folder_summary (KolabMailImapClient *self,
 	KolabFolderSummary *summary = NULL;
 	guint64 uidvalidity = 0;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, NULL);
@@ -1257,7 +1257,7 @@ kolab_mail_imap_client_query_foldernames_anon (gpointer self,
 {
 	GList *list = NULL;
 	KolabMailImapClient *myself = KOLAB_MAIL_IMAP_CLIENT (self);
-	
+
 	list = kolab_mail_imap_client_query_foldernames(myself, err);
 	return list;
 }
@@ -1270,7 +1270,7 @@ kolab_mail_imap_client_create_folder (KolabMailImapClient *self,
 	KolabMailImapClientPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1294,11 +1294,11 @@ kolab_mail_imap_client_create_folder (KolabMailImapClient *self,
 
 gboolean
 kolab_mail_imap_client_delete_folder (KolabMailImapClient *self,
-                                     const gchar *foldername,
+                                      const gchar *foldername,
                                       GError **err)
 {
 	KolabMailImapClientPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1318,7 +1318,7 @@ kolab_mail_imap_client_exists_folder (KolabMailImapClient *self,
                                       GError **err)
 {
 	KolabMailImapClientPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1372,7 +1372,7 @@ kolab_mail_imap_client_query_summaries (KolabMailImapClient *self,
 		             KOLAB_BACKEND_ERROR,
 		             KOLAB_BACKEND_ERROR_CONTEXT_MISUSE,
 		             "%s: folder type does not map to folder context for (%s)",
-			   __func__, foldername);
+		             __func__, foldername);
 		return NULL;
 	}
 
@@ -1423,7 +1423,7 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 	CamelException *tmp_ex = NULL;
 	gboolean ok = TRUE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert ((kmailhandle != NULL) || (foldername != NULL));
 	if (kmailhandle != NULL)
@@ -1446,7 +1446,7 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 		             KOLAB_BACKEND_ERROR,
 		             KOLAB_BACKEND_ERROR_INTERNAL,
 		             "%s: folder creation not yet implemented",
-		           __func__);
+		             __func__);
 		goto cleanup;
 	}
 
@@ -1457,9 +1457,9 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 		if (g_strcmp0 (handle_foldername, foldername) != 0) {
 			/* FIXME implement me */
 			g_set_error (&tmp_err,
-				     KOLAB_BACKEND_ERROR,
-				     KOLAB_BACKEND_ERROR_INTERNAL,
-				     "%s: moving object to different folder not yet implemented",
+			             KOLAB_BACKEND_ERROR,
+			             KOLAB_BACKEND_ERROR_INTERNAL,
+			             "%s: moving object to different folder not yet implemented",
 			             __func__);
 			goto cleanup;
 		}
@@ -1468,8 +1468,8 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 	/* update the CamelFolder */
 	if (update) {
 		ok = kolab_mail_imap_client_update_folder (self,
-			                                   foldername,
-			                                   &tmp_err);
+		                                           foldername,
+		                                           &tmp_err);
 		if (! ok)
 			goto cleanup;
 	}
@@ -1489,7 +1489,7 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 		             __func__, foldername);
 		goto cleanup;
 	}
-	
+
 	/* try with imap uid first */
 	summary = kolab_mail_handle_get_summary_nonconst (kmailhandle);
 	g_assert (summary != NULL);
@@ -1549,7 +1549,7 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 		goto cleanup;
 
 	tmp_ex = camel_exception_new ();
-	
+
 	/* append the new message to the imap folder */
 	camel_folder_append_message (folder,
 	                             new_message,
@@ -1595,7 +1595,7 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 		             __func__, kolab_uid, foldername);
 		goto cleanup;
 	}
-	
+
 	stored_imap_uid = g_strdup (camel_medium_get_header (CAMEL_MEDIUM (stored_message),
 	                                                     KOLAB_MAIL_IMAP_CLIENT_X_EVO_UID_HEADER));
 	if (stored_imap_uid == NULL) {
@@ -1610,7 +1610,7 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 	camel_medium_set_header (CAMEL_MEDIUM (stored_message),
 	                         KOLAB_MAIL_IMAP_CLIENT_X_EVO_UID_HEADER,
 	                         NULL);
-	
+
 	/* mark old, existing message as deleted */
 	if (orig_message != NULL) {
 		const gchar *local_imap_uid = NULL;
@@ -1621,8 +1621,8 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 		if (local_imap_uid != NULL) {
 			camel_folder_delete_message (folder, local_imap_uid);
 			camel_medium_set_header (CAMEL_MEDIUM (orig_message),
-				                 KOLAB_MAIL_IMAP_CLIENT_X_EVO_UID_HEADER,
-				                 NULL);
+			                         KOLAB_MAIL_IMAP_CLIENT_X_EVO_UID_HEADER,
+			                         NULL);
 			if (camel_exception_is_set (tmp_ex))
 				goto cleanup;
 		} else {
@@ -1650,8 +1650,8 @@ kolab_mail_imap_client_store (KolabMailImapClient *self,
 
 	/* drop kconvmail from handle */
 	kolab_mail_handle_drop_kconvmail (kmailhandle);
-	
-cleanup:
+
+ cleanup:
 	/* !! a set CamelException and a set GError are mutually exclusive here !! */
 	if (camel_exception_is_set (tmp_ex)) {
 		ok = FALSE;
@@ -1667,7 +1667,7 @@ cleanup:
 		g_propagate_error (err, tmp_err);
 	}
 	if (orig_message != NULL)
-		camel_object_unref (orig_message);	
+		camel_object_unref (orig_message);
 	if (new_message != NULL)
 		camel_object_unref (new_message);
 	if (stored_message != NULL)
@@ -1676,7 +1676,7 @@ cleanup:
 		camel_object_unref (folder);
 	if (stored_imap_uid != NULL)
 		g_free (stored_imap_uid);
-	
+
 	return ok; /* TRUE or FALSE */
 }
 
@@ -1699,7 +1699,7 @@ kolab_mail_imap_client_retrieve (KolabMailImapClient *self,
 	Kolab_conv_mail *kconvmail = NULL;
 	gboolean ok = TRUE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (KOLAB_IS_MAIL_HANDLE (kmailhandle));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1747,10 +1747,10 @@ kolab_mail_imap_client_retrieve (KolabMailImapClient *self,
 
 	if ((s_context != KOLAB_FOLDER_CONTEXT_INVAL) && (s_context != context)) {
 		g_set_error (err,
-			 KOLAB_BACKEND_ERROR,
-			 KOLAB_BACKEND_ERROR_DATATYPE_INTERNAL,
-			 "%s: UID (%s) folder context mismatch, (%i) (real) vs. (%i) (stored)",
-			 __func__, kolab_uid, context, s_context);
+		             KOLAB_BACKEND_ERROR,
+		             KOLAB_BACKEND_ERROR_DATATYPE_INTERNAL,
+		             "%s: UID (%s) folder context mismatch, (%i) (real) vs. (%i) (stored)",
+		             __func__, kolab_uid, context, s_context);
 		return FALSE;
 	}
 
@@ -1760,8 +1760,8 @@ kolab_mail_imap_client_retrieve (KolabMailImapClient *self,
 	/* update the CamelFolder */
 	if (update) {
 		ok = kolab_mail_imap_client_update_folder (self,
-			                                   foldername,
-			                                   &tmp_err);
+		                                           foldername,
+		                                           &tmp_err);
 		if (! ok) {
 			g_propagate_error (err, tmp_err);
 			return FALSE;
@@ -1852,7 +1852,7 @@ kolab_mail_imap_client_delete (KolabMailImapClient *self,
 	CamelException *tmp_ex = NULL;
 	gboolean ok = TRUE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (self));
 	g_assert (KOLAB_IS_MAIL_HANDLE (kmailhandle));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1884,8 +1884,8 @@ kolab_mail_imap_client_delete (KolabMailImapClient *self,
 	/* update the CamelFolder */
 	if (update) {
 		ok = kolab_mail_imap_client_update_folder (self,
-			                                   foldername,
-			                                   &tmp_err);
+		                                           foldername,
+		                                           &tmp_err);
 		if (! ok) {
 			g_propagate_error (err, tmp_err);
 			return FALSE;
@@ -1945,7 +1945,7 @@ kolab_mail_imap_client_delete (KolabMailImapClient *self,
 		}
 	}
 
-kolab_uid_skip:
+ kolab_uid_skip:
 
 	if (camel_message == NULL) {
 		g_warning ("%s: UID (%s) not found in folder (%s)",
@@ -1995,7 +1995,7 @@ kolab_uid_skip:
 		goto cleanup;
 	camel_folder_refresh_info (folder, tmp_ex);
 
-cleanup:
+ cleanup:
 	if (camel_exception_is_set (tmp_ex)) {
 		kolab_gerror_propagate_from_camelexception (err,
 		                                            tmp_ex,
diff --git a/src/libekolab/kolab-mail-info-db-record.c b/src/libekolab/kolab-mail-info-db-record.c
index 1b7fec2..cec57f6 100644
--- a/src/libekolab/kolab-mail-info-db-record.c
+++ b/src/libekolab/kolab-mail-info-db-record.c
@@ -242,7 +242,7 @@ kolab_mail_info_db_record_dump (const KolabMailInfoDbRecord *record)
 	         record->rdata_char[KOLAB_MAIL_INFO_DB_RECORD_CHAR_FIELD_IMAP_CHECKSUM_SYNC],
 	         record->rdata_char[KOLAB_MAIL_INFO_DB_RECORD_CHAR_FIELD_SIDE_CHECKSUM]);
 
-db_record_skip:
+ db_record_skip:
 	g_debug ("\n%s: **** InfoDB Record End ****\n", __func__);
 }
 
diff --git a/src/libekolab/kolab-mail-info-db.c b/src/libekolab/kolab-mail-info-db.c
index 17895ad..5af506b 100644
--- a/src/libekolab/kolab-mail-info-db.c
+++ b/src/libekolab/kolab-mail-info-db.c
@@ -12,12 +12,12 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
@@ -30,7 +30,7 @@
  *
  *	A generalized approach could be to use some sort of persistent
  *	GHashTable, which would be mapped transparently onto a SQLite DB
- *	(or an object oriented DB right away), with some constraints 
+ *	(or an object oriented DB right away), with some constraints
  *	applying to the hash table keys and values (as with marshalling
  *	of serializable objects). A GPersistentHashTable could be nested,
  *	binary data stored as GByteArray values and basic data types carry
@@ -152,23 +152,23 @@ kolab_mail_info_db_sql_table_create (KolabUtilSqliteDb *kdb,
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
 	switch (tbltype) {
-		case KOLAB_MAIL_INFO_DB_TABLE_TYPE_FOLDER:
-			/* row is KolabFolderSummary with folder name as primary key */
-			sql_str = sqlite3_mprintf ("CREATE TABLE IF NOT EXISTS %Q ( %Q TEXT PRIMARY KEY, \
+	case KOLAB_MAIL_INFO_DB_TABLE_TYPE_FOLDER:
+		/* row is KolabFolderSummary with folder name as primary key */
+		sql_str = sqlite3_mprintf ("CREATE TABLE IF NOT EXISTS %Q ( %Q TEXT PRIMARY KEY, \
 										    %Q INTEGER, %Q INTEGER, %Q INTEGER, %Q INTEGER, %Q INTEGER, \
 										    %Q INTEGER );",
-						   tblname,
-					           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_CHAR_FIELD_FOLDERNAME],
-					           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT_FIELD_CACHE_LOCATION],
-					           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT_FIELD_CACHE_STATUS],
-					           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT_FIELD_FOLDER_TYPE],
-					           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT_FIELD_FOLDER_CONTEXT],
-					           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT64_FIELD_UIDVALIDITY],
-					           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT64_FIELD_UIDVALIDITY_SYNC]);
-			break;
-		case KOLAB_MAIL_INFO_DB_TABLE_TYPE_RECORD:
-			/* row is KolabMailInfoDbRecord with Kolab UID as primary key */
-			sql_str = sqlite3_mprintf ("CREATE TABLE IF NOT EXISTS %Q ( %Q TEXT PRIMARY KEY, \
+		                           tblname,
+		                           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_CHAR_FIELD_FOLDERNAME],
+		                           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT_FIELD_CACHE_LOCATION],
+		                           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT_FIELD_CACHE_STATUS],
+		                           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT_FIELD_FOLDER_TYPE],
+		                           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT_FIELD_FOLDER_CONTEXT],
+		                           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT64_FIELD_UIDVALIDITY],
+		                           SCF[KOLAB_FOLDER_SUMMARY_SQLCOL_UINT64_FIELD_UIDVALIDITY_SYNC]);
+		break;
+	case KOLAB_MAIL_INFO_DB_TABLE_TYPE_RECORD:
+		/* row is KolabMailInfoDbRecord with Kolab UID as primary key */
+		sql_str = sqlite3_mprintf ("CREATE TABLE IF NOT EXISTS %Q ( %Q TEXT PRIMARY KEY, \
 										    %Q TEXT, %Q TEXT, %Q TEXT, %Q TEXT, %Q TEXT, \
 										    %Q TEXT, %Q TEXT, %Q TEXT, %Q TEXT, %Q TEXT, \
 										    %Q TEXT, %Q TEXT, %Q TEXT, %Q TEXT, \
@@ -177,46 +177,46 @@ kolab_mail_info_db_sql_table_create (KolabUtilSqliteDb *kdb,
 										    %Q INTEGER, %Q INTEGER, %Q INTEGER, \
 										    %Q TEXT, %Q TEXT, %Q TEXT, %Q TEXT, %Q TEXT, \
 										    %Q INTEGER, %Q INTEGER );",
-						   tblname,
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_KOLAB_UID],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_IMAP_UID],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_SUMMARY],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_ORGANIZER],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_LOCATION],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_CATEGORY],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_DTSTART],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_DTSTART_TZID],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_DTEND],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_DTEND_TZID],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_FULLNAME],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_EMAIL_1],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_EMAIL_2],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_EMAIL_3],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_EMAIL_4],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_FOLDER_TYPE],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_FOLDER_CONTEXT],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_CACHE_LOCATION],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_CACHE_STATUS],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_E_CLASSIFICATION],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_E_STATUS],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_INT_FIELD_E_PRIORITY],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_INT_FIELD_E_PERCENT],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_COMPLETE],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_E_HAS_ATTENDEES],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_E_HAS_ATTACHMENTS],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_E_HAS_RECURRENCE],
-			                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_E_HAS_ALARMS],
-			                           /* extra data */
-			                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_IMAP_UID_SYNC],
-			                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_IMAP_FOLDER_NAME],
-			                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_IMAP_CHECKSUM],
-			                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_IMAP_CHECKSUM_SYNC],
-			                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_SIDE_CHECKSUM],
-			                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_UINT_FIELD_IMAP_FOLDER_TYPE],
-			                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_UINT_FIELD_IMAP_FOLDER_CONTEXT]);
-			break;
-		default:
-			g_assert_not_reached ();
+		                           tblname,
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_KOLAB_UID],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_IMAP_UID],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_SUMMARY],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_ORGANIZER],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_LOCATION],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_CATEGORY],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_DTSTART],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_DTSTART_TZID],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_DTEND],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_DTEND_TZID],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_FULLNAME],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_EMAIL_1],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_EMAIL_2],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_EMAIL_3],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_CHAR_FIELD_E_EMAIL_4],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_FOLDER_TYPE],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_FOLDER_CONTEXT],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_CACHE_LOCATION],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_CACHE_STATUS],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_E_CLASSIFICATION],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_UINT_FIELD_E_STATUS],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_INT_FIELD_E_PRIORITY],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_INT_FIELD_E_PERCENT],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_COMPLETE],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_E_HAS_ATTENDEES],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_E_HAS_ATTACHMENTS],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_E_HAS_RECURRENCE],
+		                           SCR[KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_E_HAS_ALARMS],
+		                           /* extra data */
+		                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_IMAP_UID_SYNC],
+		                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_IMAP_FOLDER_NAME],
+		                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_IMAP_CHECKSUM],
+		                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_IMAP_CHECKSUM_SYNC],
+		                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_SIDE_CHECKSUM],
+		                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_UINT_FIELD_IMAP_FOLDER_TYPE],
+		                           SCR[KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_UINT_FIELD_IMAP_FOLDER_CONTEXT]);
+		break;
+	default:
+		g_assert_not_reached ();
 	}
 
 	ok = kolab_util_sqlite_exec_str (kdb, sql_str, &tmp_err);
@@ -226,7 +226,7 @@ kolab_mail_info_db_sql_table_create (KolabUtilSqliteDb *kdb,
 		return FALSE;
 	}
 
-	return TRUE;	
+	return TRUE;
 }
 
 static gboolean
@@ -237,7 +237,7 @@ kolab_mail_info_db_sql_update_folder (KolabUtilSqliteDb *kdb,
 	gchar *sql_str = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (kdb != NULL);
 	g_assert (kdb->db != NULL);
 	g_assert (summary != NULL);
@@ -267,7 +267,7 @@ kolab_mail_info_db_sql_update_folder (KolabUtilSqliteDb *kdb,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	return TRUE;
 }
 
@@ -275,9 +275,9 @@ static gchar*
 kolab_mail_info_db_sql_record_new_tblname (const gchar *foldername)
 {
 	gchar *tblname = NULL;
-	
+
 	g_assert (foldername != NULL);
-	
+
 	tblname = g_strconcat (KOLAB_MAIL_INFO_DB_SQLITE_DB_TBL_RECORDS,
 	                       foldername,
 	                       NULL);
@@ -294,7 +294,7 @@ kolab_mail_info_db_sql_update_record (KolabUtilSqliteDb *kdb,
 	gchar *sql_str = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (kdb != NULL);
 	g_assert (kdb->db != NULL);
 	g_assert (record != NULL);
@@ -401,7 +401,7 @@ kolab_mail_info_db_sql_update_record (KolabUtilSqliteDb *kdb,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	return TRUE;
 }
 
@@ -415,7 +415,7 @@ kolab_mail_info_db_sql_folder_new_from_stmt (sqlite3_stmt *sql_stmt)
 
 	if (sql_stmt == NULL)
 		return NULL;
-	
+
 	summary = kolab_folder_summary_new ();
 
 	/* folder name */
@@ -474,7 +474,7 @@ kolab_mail_info_db_sql_query_folder (KolabUtilSqliteDb *kdb,
 	sqlite3_stmt *sql_stmt = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (kdb != NULL);
 	g_assert (kdb->db != NULL);
 	g_assert (foldername != NULL);
@@ -491,16 +491,16 @@ kolab_mail_info_db_sql_query_folder (KolabUtilSqliteDb *kdb,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	/* get folder summary row from db */
 	sql_errno = sqlite3_step (sql_stmt);
 	if (sql_errno != SQLITE_ROW) {
-		if (sql_errno != SQLITE_DONE) {		
+		if (sql_errno != SQLITE_DONE) {
 			g_set_error (err,
 			             KOLAB_UTIL_ERROR,
 			             KOLAB_UTIL_ERROR_SQLITE_DB,
-				     "%s: %s",
-				     __func__, sqlite3_errmsg (kdb->db));
+			             "%s: %s",
+			             __func__, sqlite3_errmsg (kdb->db));
 		}
 		(void)kolab_util_sqlite_fnlz_stmt (kdb, sql_stmt, NULL);
 		return NULL;
@@ -508,14 +508,14 @@ kolab_mail_info_db_sql_query_folder (KolabUtilSqliteDb *kdb,
 
 	/* get new folder summary from prep'ed statement */
 	summary = kolab_mail_info_db_sql_folder_new_from_stmt (sql_stmt);
-	
+
 	ok = kolab_util_sqlite_fnlz_stmt (kdb, sql_stmt, &tmp_err);
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
 		kolab_folder_summary_free (summary);
 		return NULL;
 	}
-	
+
 	return summary;
 }
 
@@ -528,10 +528,10 @@ kolab_mail_info_db_sql_record_new_from_stmt (sqlite3_stmt *sql_stmt)
 	gint tmp_int = 0;
 	gint ii = 0;
 	gint msi = 0;
-	
+
 	if (sql_stmt == NULL)
 		return NULL;
-	
+
 	record = kolab_mail_info_db_record_new ();
 	record->summary = kolab_mail_summary_new ();
 
@@ -556,7 +556,7 @@ kolab_mail_info_db_sql_record_new_from_stmt (sqlite3_stmt *sql_stmt)
 	     ii++) {
 		msi = ii - KOLAB_MAIL_SUMMARY_SQLCOL_INT_FIELD_E_PRIORITY;
 		tmp_int = sqlite3_column_int (sql_stmt, ii);
-		kolab_mail_summary_set_int_field (record->summary, msi, tmp_int);		
+		kolab_mail_summary_set_int_field (record->summary, msi, tmp_int);
 	}
 
 	for (ii = KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_COMPLETE;
@@ -564,7 +564,7 @@ kolab_mail_info_db_sql_record_new_from_stmt (sqlite3_stmt *sql_stmt)
 	     ii++) {
 		msi = ii - KOLAB_MAIL_SUMMARY_SQLCOL_BOOL_FIELD_COMPLETE;
 		tmp_int = sqlite3_column_int (sql_stmt, ii);
-		kolab_mail_summary_set_bool_field (record->summary, msi, tmp_int);		
+		kolab_mail_summary_set_bool_field (record->summary, msi, tmp_int);
 	}
 
 	for (ii = KOLAB_MAIL_INFO_DB_RECORD_SQLCOL_CHAR_FIELD_IMAP_UID_SYNC;
@@ -587,14 +587,14 @@ kolab_mail_info_db_sql_record_new_from_stmt (sqlite3_stmt *sql_stmt)
 	kolab_mail_summary_set_bool_field (record->summary,
 	                                   KOLAB_MAIL_SUMMARY_BOOL_FIELD_COMPLETE,
 	                                   FALSE);
-	return record;                                                  
+	return record;
 }
 
 static KolabMailInfoDbRecord*
 kolab_mail_info_db_sql_query_record (KolabUtilSqliteDb *kdb,
-                                      const gchar *uid,
-                                      const gchar *foldername,
-                                      GError **err)
+                                     const gchar *uid,
+                                     const gchar *foldername,
+                                     GError **err)
 {
 	KolabMailInfoDbRecord *record = NULL;
 	gchar *tblname = NULL;
@@ -625,16 +625,16 @@ kolab_mail_info_db_sql_query_record (KolabUtilSqliteDb *kdb,
 		g_propagate_error (err, tmp_err);
 		return NULL;
 	}
-	
+
 	/* get record row from db */
 	sql_errno = sqlite3_step (sql_stmt);
 	if (sql_errno != SQLITE_ROW) {
-		if (sql_errno != SQLITE_DONE) {		
+		if (sql_errno != SQLITE_DONE) {
 			g_set_error (err,
 			             KOLAB_UTIL_ERROR,
 			             KOLAB_UTIL_ERROR_SQLITE_DB,
-				     "%s: %s",
-				     __func__, sqlite3_errmsg (kdb->db));
+			             "%s: %s",
+			             __func__, sqlite3_errmsg (kdb->db));
 		}
 		(void)kolab_util_sqlite_fnlz_stmt (kdb, sql_stmt, NULL);
 		g_free (tblname);
@@ -643,7 +643,7 @@ kolab_mail_info_db_sql_query_record (KolabUtilSqliteDb *kdb,
 
 	/* get new InfoDb record from prep'ed statement */
 	record = kolab_mail_info_db_sql_record_new_from_stmt (sql_stmt);
-	
+
 	ok = kolab_util_sqlite_fnlz_stmt (kdb, sql_stmt, &tmp_err);
 	g_free (tblname);
 	if (! ok) {
@@ -694,7 +694,7 @@ kolab_mail_info_db_sql_remove_record (KolabUtilSqliteDb *kdb,
 	gchar *sql_str = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (kdb != NULL);
 	g_assert (kdb->db != NULL);
 	g_assert (uid != NULL);
@@ -732,7 +732,7 @@ kolab_mail_info_db_init (KolabMailInfoDb *object)
 	KolabMailInfoDbPrivate *priv = NULL;
 
 	g_assert (KOLAB_IS_MAIL_INFO_DB (object));
-	
+
 	self = object;
 	priv = KOLAB_MAIL_INFO_DB_PRIVATE (self);
 
@@ -799,7 +799,7 @@ kolab_mail_info_db_configure  (KolabMailInfoDb *self,
                                GError **err)
 {
 	KolabMailInfoDbPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (ksettings));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -811,7 +811,7 @@ kolab_mail_info_db_configure  (KolabMailInfoDb *self,
 
 	g_object_ref (ksettings); /* unref'd in dispose() */
 	priv->ksettings = ksettings;
-		
+
 	return TRUE;
 }
 
@@ -822,7 +822,7 @@ kolab_mail_info_db_bringup (KolabMailInfoDb *self,
 	KolabMailInfoDbPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -855,7 +855,7 @@ kolab_mail_info_db_bringup (KolabMailInfoDb *self,
 	                                       g_str_equal,
 	                                       g_free,
 	                                       kolab_mail_info_db_record_gdestroy);
-	
+
 	priv->is_up = TRUE;
 	return TRUE;
 }
@@ -867,7 +867,7 @@ kolab_mail_info_db_shutdown (KolabMailInfoDb *self,
 	KolabMailInfoDbPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -888,7 +888,7 @@ kolab_mail_info_db_shutdown (KolabMailInfoDb *self,
 	g_hash_table_destroy (priv->cache_r);
 	priv->cache_fs = NULL;
 	priv->cache_r = NULL;
-	
+
 	priv->is_up = FALSE;
 	return TRUE;
 }
@@ -910,7 +910,7 @@ kolab_mail_info_db_query_uids (KolabMailInfoDb *self,
 	gchar *tblname = NULL;
 	gchar *sql_str = NULL;
 	gint sql_errno = SQLITE_OK;
-	sqlite3_stmt *sql_stmt = NULL;	
+	sqlite3_stmt *sql_stmt = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
 
@@ -959,12 +959,12 @@ kolab_mail_info_db_query_uids (KolabMailInfoDb *self,
 		/* get record row from db */
 		sql_errno = sqlite3_step (sql_stmt);
 		if (sql_errno != SQLITE_ROW) {
-			if (sql_errno != SQLITE_DONE) {		
+			if (sql_errno != SQLITE_DONE) {
 				g_set_error (&tmp_err,
-					     KOLAB_UTIL_ERROR,
-					     KOLAB_UTIL_ERROR_SQLITE_DB,
-					     "%s: %s",
-					     __func__, sqlite3_errmsg (priv->kdb->db));
+				             KOLAB_UTIL_ERROR,
+				             KOLAB_UTIL_ERROR_SQLITE_DB,
+				             "%s: %s",
+				             __func__, sqlite3_errmsg (priv->kdb->db));
 			}
 			break;
 		}
@@ -991,19 +991,19 @@ kolab_mail_info_db_query_uids (KolabMailInfoDb *self,
 			if (! (location & KOLAB_OBJECT_CACHE_LOCATION_SIDE))
 				goto skip_uid;
 		}
-			
+
 	include_uid:
 		uids_lst = g_list_prepend (uids_lst, g_strdup (uid));
 	skip_uid:
 		kolab_mail_info_db_record_free (record);
 	}
-	                                                  
+
 	if (tmp_err == NULL) {
 		ok = kolab_util_sqlite_fnlz_stmt (priv->kdb, sql_stmt, &tmp_err);
 	} else {
 		(void)kolab_util_sqlite_fnlz_stmt (priv->kdb, sql_stmt, NULL);
 		ok = FALSE;
-	}	
+	}
 	if (! ok) {
 		kolab_util_glib_glist_free (uids_lst);
 		g_propagate_error (err, tmp_err);
@@ -1029,7 +1029,7 @@ kolab_mail_info_db_query_changed_uids (KolabMailInfoDb *self,
 	gchar *tblname = NULL;
 	gchar *sql_str = NULL;
 	gint sql_errno = SQLITE_OK;
-	sqlite3_stmt *sql_stmt = NULL;	
+	sqlite3_stmt *sql_stmt = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
 
@@ -1084,12 +1084,12 @@ kolab_mail_info_db_query_changed_uids (KolabMailInfoDb *self,
 		/* get record row from db */
 		sql_errno = sqlite3_step (sql_stmt);
 		if (sql_errno != SQLITE_ROW) {
-			if (sql_errno != SQLITE_DONE) {		
+			if (sql_errno != SQLITE_DONE) {
 				g_set_error (&tmp_err,
-					     KOLAB_UTIL_ERROR,
-					     KOLAB_UTIL_ERROR_SQLITE_DB,
-					     "%s: %s",
-					     __func__, sqlite3_errmsg (priv->kdb->db));
+				             KOLAB_UTIL_ERROR,
+				             KOLAB_UTIL_ERROR_SQLITE_DB,
+				             "%s: %s",
+				             __func__, sqlite3_errmsg (priv->kdb->db));
 			}
 			break;
 		}
@@ -1097,7 +1097,7 @@ kolab_mail_info_db_query_changed_uids (KolabMailInfoDb *self,
 		/* read needed values */
 		record = kolab_mail_info_db_sql_record_new_from_stmt (sql_stmt);
 		g_assert (record->summary != NULL);
-		
+
 		/* TODO check folder context */
 		uid = kolab_mail_summary_get_char_field (record->summary,
 		                                         KOLAB_MAIL_SUMMARY_CHAR_FIELD_KOLAB_UID);
@@ -1111,7 +1111,7 @@ kolab_mail_info_db_query_changed_uids (KolabMailInfoDb *self,
 		    (status & (guint)KOLAB_OBJECT_CACHE_STATUS_DELETED)) {
 			if (full_update) {
 				deleted_uids_lst = g_list_prepend (deleted_uids_lst,
-					                           g_strdup (uid));
+				                                   g_strdup (uid));
 			}
 			kolab_mail_info_db_record_free (record);
 			continue;
@@ -1121,7 +1121,7 @@ kolab_mail_info_db_query_changed_uids (KolabMailInfoDb *self,
 			kolab_mail_info_db_record_free (record);
 			continue;
 		}
-		
+
 		uids_lst = g_list_prepend (uids_lst, g_strdup (uid));
 
 		if (full_update) {
@@ -1136,13 +1136,13 @@ kolab_mail_info_db_query_changed_uids (KolabMailInfoDb *self,
 			kolab_mail_info_db_record_free (record);
 		}
 	}
-	                                                  
+
 	if (tmp_err == NULL) {
 		ok = kolab_util_sqlite_fnlz_stmt (priv->kdb, sql_stmt, &tmp_err);
 	} else {
 		(void)kolab_util_sqlite_fnlz_stmt (priv->kdb, sql_stmt, NULL);
 		ok = FALSE;
-	}	
+	}
 	if (! ok) {
 		g_hash_table_destroy (records_upd_tbl);
 		g_propagate_error (err, tmp_err);
@@ -1160,14 +1160,14 @@ kolab_mail_info_db_query_changed_uids (KolabMailInfoDb *self,
 			record = g_hash_table_lookup (records_upd_tbl, uid);
 			if (record == NULL) {
 				ok = kolab_mail_info_db_remove_record (self,
-					                               uid,
-					                               foldername,
-					                               &tmp_err);
+				                                       uid,
+				                                       foldername,
+				                                       &tmp_err);
 			} else {
 				ok = kolab_mail_info_db_update_record (self,
-					                               record,
-					                               foldername,
-					                               &tmp_err);
+				                                       record,
+				                                       foldername,
+				                                       &tmp_err);
 				g_hash_table_remove (records_upd_tbl, uid);
 			}
 			if (! ok) {
@@ -1193,7 +1193,7 @@ kolab_mail_info_db_query_foldernames (KolabMailInfoDb *self,
 	KolabMailInfoDbPrivate *priv = NULL;
 	GList *foldernames_list = NULL;
 	gchar *sql_str = NULL;
-	sqlite3_stmt *sql_stmt = NULL;	
+	sqlite3_stmt *sql_stmt = NULL;
 	gint sql_errno = SQLITE_OK;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
@@ -1222,12 +1222,12 @@ kolab_mail_info_db_query_foldernames (KolabMailInfoDb *self,
 		/* get folder row from db */
 		sql_errno = sqlite3_step (sql_stmt);
 		if (sql_errno != SQLITE_ROW) {
-			if (sql_errno != SQLITE_DONE) {		
+			if (sql_errno != SQLITE_DONE) {
 				g_set_error (&tmp_err,
-					     KOLAB_UTIL_ERROR,
-					     KOLAB_UTIL_ERROR_SQLITE_DB,
-					     "%s: %s",
-					     __func__, sqlite3_errmsg (priv->kdb->db));
+				             KOLAB_UTIL_ERROR,
+				             KOLAB_UTIL_ERROR_SQLITE_DB,
+				             "%s: %s",
+				             __func__, sqlite3_errmsg (priv->kdb->db));
 			}
 			break;
 		}
@@ -1241,7 +1241,7 @@ kolab_mail_info_db_query_foldernames (KolabMailInfoDb *self,
 			goto folder_skip;
 
 		/* TODO more folder checks needed? */
-		
+
 		foldernames_list = g_list_prepend (foldernames_list,
 		                                   g_strdup (foldername));
 	folder_skip:
@@ -1253,7 +1253,7 @@ kolab_mail_info_db_query_foldernames (KolabMailInfoDb *self,
 	} else {
 		(void)kolab_util_sqlite_fnlz_stmt (priv->kdb, sql_stmt, NULL);
 		ok = FALSE;
-	}	
+	}
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
 		kolab_util_glib_glist_free (foldernames_list);
@@ -1269,7 +1269,7 @@ kolab_mail_info_db_query_foldernames_anon (gpointer self,
 {
 	GList *list = NULL;
 	KolabMailInfoDb *myself = KOLAB_MAIL_INFO_DB (self);
-	
+
 	list = kolab_mail_info_db_query_foldernames (myself, err);
 	return list;
 }
@@ -1282,7 +1282,7 @@ kolab_mail_info_db_exists_foldername (KolabMailInfoDb *self,
 	KolabMailInfoDbPrivate *priv = NULL;
 	KolabFolderSummary *summary = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1298,7 +1298,7 @@ kolab_mail_info_db_exists_foldername (KolabMailInfoDb *self,
 		if (g_strcmp0 (cfs_fn, foldername) == 0)
 			return TRUE;
 	}
-	
+
 	summary = kolab_mail_info_db_sql_query_folder (priv->kdb,
 	                                               foldername,
 	                                               &tmp_err);
@@ -1312,7 +1312,7 @@ kolab_mail_info_db_exists_foldername (KolabMailInfoDb *self,
 
 	kolab_folder_summary_free (priv->cache_fs);
 	priv->cache_fs = summary;
-	
+
 	return TRUE;
 }
 
@@ -1320,11 +1320,11 @@ KolabFolderSummary*
 kolab_mail_info_db_query_folder_summary (KolabMailInfoDb *self,
                                          const gchar *foldername,
                                          GError **err)
-{	
+{
 	KolabMailInfoDbPrivate *priv = NULL;
 	KolabFolderSummary *summary = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1359,7 +1359,7 @@ kolab_mail_info_db_query_folder_summary (KolabMailInfoDb *self,
 
 	kolab_folder_summary_free (priv->cache_fs);
 	priv->cache_fs = summary;
-	
+
 	return kolab_folder_summary_clone (priv->cache_fs);
 }
 
@@ -1372,7 +1372,7 @@ kolab_mail_info_db_update_folder_summary (KolabMailInfoDb *self,
 	const gchar *foldername = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_assert (summary != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1423,7 +1423,7 @@ kolab_mail_info_db_remove_folder (KolabMailInfoDb *self,
 	gchar *tblname = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1448,7 +1448,7 @@ kolab_mail_info_db_remove_folder (KolabMailInfoDb *self,
 		             __func__, foldername);
 		return FALSE;
 	}
-	
+
 	/* remove folder summary from folders table */
 	ok = kolab_mail_info_db_sql_remove_folder (priv->kdb,
 	                                           foldername,
@@ -1490,7 +1490,7 @@ kolab_mail_info_db_query_mail_summary (KolabMailInfoDb *self,
 	KolabMailInfoDbRecord *record = NULL;
 	KolabMailSummary *summary = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
@@ -1505,7 +1505,7 @@ kolab_mail_info_db_query_mail_summary (KolabMailInfoDb *self,
 		g_propagate_error (err, tmp_err);
 		return NULL;
 	}
-	
+
 	if (record == NULL)
 		return NULL;
 
@@ -1533,7 +1533,7 @@ kolab_mail_info_db_query_record (KolabMailInfoDb *self,
 	gchar *tblname = NULL;
 	gboolean exists = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
@@ -1582,7 +1582,7 @@ kolab_mail_info_db_query_record (KolabMailInfoDb *self,
 	folder_summary = kolab_mail_info_db_query_folder_summary (self,
 	                                                          foldername,
 	                                                          &tmp_err);
-		
+
 	if (tmp_err != NULL) {
 		kolab_mail_info_db_record_free (record);
 		g_propagate_error (err, tmp_err);
@@ -1623,7 +1623,7 @@ kolab_mail_info_db_update_record (KolabMailInfoDb *self,
                                   const KolabMailInfoDbRecord *record,
                                   const gchar *foldername,
                                   GError **err)
-{	
+{
 	KolabMailInfoDbPrivate *priv = NULL;
 	KolabFolderSummary *folder_summary = NULL;
 	KolabObjectCacheLocation location = KOLAB_OBJECT_CACHE_LOCATION_INVAL;
@@ -1635,7 +1635,7 @@ kolab_mail_info_db_update_record (KolabMailInfoDb *self,
 	g_assert (record != NULL);
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
-	
+
 	priv = KOLAB_MAIL_INFO_DB_PRIVATE (self);
 
 	g_assert (priv->is_up == TRUE);
@@ -1696,7 +1696,7 @@ kolab_mail_info_db_update_record (KolabMailInfoDb *self,
 	                      g_strdup (foldername),
 	                      kolab_mail_info_db_record_clone (record));
 	return TRUE;
-} 
+}
 
 gboolean
 kolab_mail_info_db_remove_record (KolabMailInfoDb *self,
@@ -1708,7 +1708,7 @@ kolab_mail_info_db_remove_record (KolabMailInfoDb *self,
 	KolabMailInfoDbRecord *record = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
@@ -1720,9 +1720,9 @@ kolab_mail_info_db_remove_record (KolabMailInfoDb *self,
 
 	/* TODO need a more efficient implementation here */
 	record = kolab_mail_info_db_sql_query_record (priv->kdb,
-	                                               uid,
-	                                               foldername,
-	                                               &tmp_err);
+	                                              uid,
+	                                              foldername,
+	                                              &tmp_err);
 	if (tmp_err != NULL) {
 		g_propagate_error (err, tmp_err);
 		return FALSE;
@@ -1750,7 +1750,7 @@ kolab_mail_info_db_remove_record (KolabMailInfoDb *self,
 
 	/* drop record from cache */
 	g_hash_table_remove (priv->cache_r, foldername);
-	
+
 	return TRUE;
 }
 
@@ -1763,7 +1763,7 @@ kolab_mail_info_db_transaction_start (KolabMailInfoDb *self, GError **err)
 	KolabMailInfoDbPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1786,7 +1786,7 @@ kolab_mail_info_db_transaction_commit (KolabMailInfoDb *self, GError **err)
 	KolabMailInfoDbPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1809,7 +1809,7 @@ kolab_mail_info_db_transaction_abort (KolabMailInfoDb *self, GError **err)
 	KolabMailInfoDbPrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_INFO_DB (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
diff --git a/src/libekolab/kolab-mail-mime-builder.c b/src/libekolab/kolab-mail-mime-builder.c
index 6487ef2..a41ce21 100644
--- a/src/libekolab/kolab-mail-mime-builder.c
+++ b/src/libekolab/kolab-mail-mime-builder.c
@@ -12,17 +12,17 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
  */
- 
+
 /*----------------------------------------------------------------------------*/
 
 #include <string.h>
@@ -35,8 +35,8 @@
 #define KOLAB_MAIL_MIME_PARTS_MIN 2
 #define KOLAB_MAIL_MIME_PART_DUMMY_NAME "evolution-kolab-dummy-name"
 
-#define KOLAB_MAIL_MIME_PART_ZEROTH_CONTENT \
-"Dies ist ein Kolab Groupware-Objekt. \
+#define KOLAB_MAIL_MIME_PART_ZEROTH_CONTENT	  \
+	"Dies ist ein Kolab Groupware-Objekt. \
 Um dieses Objekt anzeigen zu koennen, brauchen Sie ein E-Mail Programm, \
 das das Kolab Groupware-Format versteht. \
 Eine Liste solcher E-Mail-Programme finden Sie hier: \
@@ -75,7 +75,7 @@ kolab_mail_mime_builder_init (KolabMailMimeBuilder *object)
 	KolabMailMimeBuilderPrivate *priv = NULL;
 
 	g_assert (KOLAB_IS_MAIL_MIME_BUILDER (object));
-	
+
 	self = object;
 	priv = KOLAB_MAIL_MIME_BUILDER_PRIVATE (self);
 
@@ -135,7 +135,7 @@ kolab_mail_mime_builder_configure  (KolabMailMimeBuilder *self,
                                     GError **err)
 {
 	KolabMailMimeBuilderPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_MIME_BUILDER (self));
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (ksettings));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -149,7 +149,7 @@ kolab_mail_mime_builder_configure  (KolabMailMimeBuilder *self,
 	priv->ksettings = ksettings;
 
 	/* TODO implement me */
-	
+
 	return TRUE;
 }
 
@@ -158,7 +158,7 @@ kolab_mail_mime_builder_bringup (KolabMailMimeBuilder *self,
                                  GError **err)
 {
 	KolabMailMimeBuilderPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_MIME_BUILDER (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -166,7 +166,7 @@ kolab_mail_mime_builder_bringup (KolabMailMimeBuilder *self,
 
 	if (priv->is_up == TRUE)
 		return TRUE;
-	
+
 	/* TODO implement me */
 
 	priv->is_up = TRUE;
@@ -178,7 +178,7 @@ kolab_mail_mime_builder_shutdown (KolabMailMimeBuilder *self,
                                   GError **err)
 {
 	KolabMailMimeBuilderPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_MIME_BUILDER (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -186,7 +186,7 @@ kolab_mail_mime_builder_shutdown (KolabMailMimeBuilder *self,
 
 	if (priv->is_up == FALSE)
 		return TRUE;
-	
+
 	/* TODO implement me */
 
 	priv->is_up = FALSE;
@@ -208,7 +208,7 @@ kolab_mail_mime_builder_conv_new_from_camel (KolabMailMimeBuilder *self,
 	guint nparts = 0;
 	guint ii = 0;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_MIME_BUILDER (self));
 	g_assert (CAMEL_IS_MIME_MESSAGE (message));
 	g_return_val_if_fail (err == NULL || *err == NULL, NULL);
@@ -223,7 +223,7 @@ kolab_mail_mime_builder_conv_new_from_camel (KolabMailMimeBuilder *self,
 		             KOLAB_BACKEND_ERROR,
 		             KOLAB_BACKEND_ERROR_CAMEL,
 		             "%s: cannot unpack CamelMimeMessage",
-		           __func__);
+		             __func__);
 		return NULL;
 	}
 
@@ -234,9 +234,9 @@ kolab_mail_mime_builder_conv_new_from_camel (KolabMailMimeBuilder *self,
 		             "%s: no multipart message, ignoring",
 		             __func__);
 		/* need to unref data wrapper? */
-		return NULL;		
+		return NULL;
 	}
-	
+
 	multipart = CAMEL_MULTIPART (data_wrapper);
 
 	nparts = camel_multipart_get_number (multipart);
@@ -269,7 +269,7 @@ kolab_mail_mime_builder_conv_new_from_camel (KolabMailMimeBuilder *self,
 		gchar *content_type_str = NULL;
 		gssize stream_bytes = 0;
 		mimepart = camel_multipart_get_part (multipart, ii);
-		
+
 		content_type = camel_mime_part_get_content_type (mimepart);
 		content_type_str = camel_content_type_simple (content_type);
 		name = camel_mime_part_get_filename (mimepart);
@@ -279,7 +279,7 @@ kolab_mail_mime_builder_conv_new_from_camel (KolabMailMimeBuilder *self,
 
 		/* content checks */
 		/* TODO more detail in warning messages */
-		
+
 		if (content_type_str == NULL) {
 			g_set_error (&tmp_err,
 			             KOLAB_BACKEND_ERROR,
@@ -349,7 +349,7 @@ kolab_mail_mime_builder_conv_new_from_camel (KolabMailMimeBuilder *self,
 		if (tmp_err != NULL)
 			break;
 	}
-	
+
 	/* need to unref data wrapper? */
 
 	/* if anything went wrong, free all mem */
@@ -359,7 +359,7 @@ kolab_mail_mime_builder_conv_new_from_camel (KolabMailMimeBuilder *self,
 		g_free (kconvmail);
 		return NULL;
 	}
-	
+
 	return kconvmail;
 }
 
@@ -401,7 +401,7 @@ kolab_mail_mime_builder_camel_new_from_conv (KolabMailMimeBuilder *self,
 	gchar *msg_mimetype = NULL;
 	guint ii = 0;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_MIME_BUILDER (self));
 	g_assert (kconvmail != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -457,7 +457,7 @@ kolab_mail_mime_builder_camel_new_from_conv (KolabMailMimeBuilder *self,
 			g_warning ("%s: NULL kconvmailpart->data", __func__);
 			ok = FALSE;
 		}
-		
+
 		if (! ok) {
 			/* should never happen */
 			g_set_error (&tmp_err,
@@ -467,12 +467,12 @@ kolab_mail_mime_builder_camel_new_from_conv (KolabMailMimeBuilder *self,
 			             __func__);
 			goto mime_part_skip;
 		}
-		
+
 		memstream = CAMEL_STREAM_MEM (camel_stream_mem_new ());
 		stream_bytes = camel_stream_write (CAMEL_STREAM (memstream),
 		                                   kconvmailpart->data,
 		                                   kconvmailpart->length);
-		if (stream_bytes < 0) {			
+		if (stream_bytes < 0) {
 			g_set_error (&tmp_err,
 			             KOLAB_BACKEND_ERROR,
 			             KOLAB_BACKEND_ERROR_CAMEL,
@@ -497,7 +497,7 @@ kolab_mail_mime_builder_camel_new_from_conv (KolabMailMimeBuilder *self,
 		mimepart = camel_mime_part_new ();
 		camel_medium_set_content_object (CAMEL_MEDIUM (mimepart),
 		                                 data_wrapper);
-	
+
 		camel_mime_part_set_filename (mimepart,
 		                              kconvmailpart->name);
 
@@ -514,9 +514,9 @@ kolab_mail_mime_builder_camel_new_from_conv (KolabMailMimeBuilder *self,
 			camel_mime_part_set_encoding (mimepart,
 			                              CAMEL_TRANSFER_ENCODING_8BIT);
 		}
-		
+
 		camel_multipart_add_part (multipart, mimepart);
-		
+
 	mime_part_skip:
 		if (memstream != NULL)
 			camel_object_unref (memstream);
diff --git a/src/libekolab/kolab-mail-side-cache.c b/src/libekolab/kolab-mail-side-cache.c
index b89f111..4bd882b 100644
--- a/src/libekolab/kolab-mail-side-cache.c
+++ b/src/libekolab/kolab-mail-side-cache.c
@@ -12,12 +12,12 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
@@ -30,7 +30,7 @@
  *
  *	A generalized approach could be to use some sort of persistent
  *	GHashTable, which would be mapped transparently onto a SQLite DB
- *	(or an object oriented DB right away), with some constraints 
+ *	(or an object oriented DB right away), with some constraints
  *	applying to the hash table keys and values (as with marshalling
  *	of serializable objects). A GPersistentHashTable could be nested,
  *	binary data stored as GByteArray values and basic data types carry
@@ -113,7 +113,7 @@ kolab_mail_side_cache_sql_table_create (KolabUtilSqliteDb *kdb,
 	sql_str = sqlite3_mprintf ("CREATE TABLE IF NOT EXISTS %Q ( %Q INTEGER PRIMARY KEY, \
 								    %Q TEXT, %Q TEXT, %Q INTEGER, \
 								    %Q BLOB );",
-				   tblname,
+	                           tblname,
 	                           SCS[KOLAB_CONV_MAIL_SQLCOL_FIELD_INDEX],
 	                           SCS[KOLAB_CONV_MAIL_SQLCOL_FIELD_NAME],
 	                           SCS[KOLAB_CONV_MAIL_SQLCOL_FIELD_MIME_TYPE],
@@ -127,7 +127,7 @@ kolab_mail_side_cache_sql_table_create (KolabUtilSqliteDb *kdb,
 		return FALSE;
 	}
 
-	return TRUE;	
+	return TRUE;
 }
 
 static gchar*
@@ -135,10 +135,10 @@ kolab_mail_side_cache_sql_new_tblname (const gchar *uid,
                                        const gchar *foldername)
 {
 	gchar *tblname = NULL;
-	
+
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
-	
+
 	tblname = g_strconcat (foldername, uid, NULL);
 	return tblname;
 }
@@ -153,15 +153,15 @@ kolab_mail_side_cache_sql_delete_by_uid (KolabUtilSqliteDb *kdb,
 	gboolean exists = FALSE;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (kdb != NULL);
 	g_assert (kdb->db != NULL);
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
-	
+
 	tblname = kolab_mail_side_cache_sql_new_tblname (uid, foldername);
-	
+
 	/* check if object exists */
 	exists = kolab_util_sqlite_table_exists (kdb, tblname, &tmp_err);
 	if (tmp_err != NULL) {
@@ -201,7 +201,7 @@ kolab_mail_side_cache_sql_delete_folder (KolabUtilSqliteDb *kdb,
 	 *      - drop these tables
 	 */
 	g_warning ("%s: not yet implemented", __func__);
-	
+
 	return TRUE;
 }
 
@@ -220,15 +220,15 @@ kolab_mail_side_cache_sql_query_object (KolabUtilSqliteDb *kdb,
 	gboolean exists = FALSE;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (kdb != NULL);
 	g_assert (kdb->db != NULL);
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, NULL);
-	
+
 	tblname = kolab_mail_side_cache_sql_new_tblname (uid, foldername);
-	
+
 	/* check if object exists */
 	exists = kolab_util_sqlite_table_exists (kdb, tblname, &tmp_err);
 	if (tmp_err != NULL) {
@@ -255,9 +255,9 @@ kolab_mail_side_cache_sql_query_object (KolabUtilSqliteDb *kdb,
 		             KOLAB_BACKEND_ERROR,
 		             KOLAB_BACKEND_ERROR_DATATYPE_KOLAB,
 		             "%s: UID (%s) Folder (%s) has zero mail parts",
-		           __func__, uid, foldername);
+		             __func__, uid, foldername);
 		g_free (tblname);
-		return NULL;		             
+		return NULL;
 	}
 
 	/* prep statement for reading table */
@@ -279,16 +279,16 @@ kolab_mail_side_cache_sql_query_object (KolabUtilSqliteDb *kdb,
 		gint  rowidx = 0;
 		guint nbytes = 0;
 		Kolab_conv_mail_part *mpart = NULL;
-		
+
 		/* get record row from db */
 		sql_errno = sqlite3_step (sql_stmt);
 		if (sql_errno != SQLITE_ROW) {
-			if (sql_errno != SQLITE_DONE) {		
+			if (sql_errno != SQLITE_DONE) {
 				g_set_error (&tmp_err,
-					     KOLAB_UTIL_ERROR,
-					     KOLAB_UTIL_ERROR_SQLITE_DB,
-					     "%s: %s",
-					     __func__, sqlite3_errmsg (kdb->db));
+				             KOLAB_UTIL_ERROR,
+				             KOLAB_UTIL_ERROR_SQLITE_DB,
+				             "%s: %s",
+				             __func__, sqlite3_errmsg (kdb->db));
 			}
 			break;
 		}
@@ -306,7 +306,7 @@ kolab_mail_side_cache_sql_query_object (KolabUtilSqliteDb *kdb,
 		if (mpart->length != nbytes) {
 			g_set_error (&tmp_err,
 			             KOLAB_UTIL_ERROR,
-				     KOLAB_UTIL_ERROR_SQLITE_DB,
+			             KOLAB_UTIL_ERROR_SQLITE_DB,
 			             "%s: UID (%s) Folder (%s) expected (%i) payload bytes, got (%i)",
 			             __func__, uid, foldername, mpart->length, nbytes);
 			break;
@@ -323,19 +323,19 @@ kolab_mail_side_cache_sql_query_object (KolabUtilSqliteDb *kdb,
 			mpart->data = NULL;
 		}
 	}
-	                                                  
+
 	if (tmp_err == NULL) {
 		ok = kolab_util_sqlite_fnlz_stmt (kdb, sql_stmt, &tmp_err);
 	} else {
 		(void)kolab_util_sqlite_fnlz_stmt (kdb, sql_stmt, NULL);
 		ok = FALSE;
-	}	
+	}
 	if (! ok) {
 		kolabconv_free_kmail (kconvmail);
 		g_propagate_error (err, tmp_err);
 		return NULL;
 	}
-	
+
 	return kconvmail;
 }
 
@@ -351,16 +351,16 @@ kolab_mail_side_cache_sql_store_object (KolabUtilSqliteDb *kdb,
 	gboolean exists = FALSE;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (kdb != NULL);
 	g_assert (kdb->db != NULL);
 	g_assert (kconvmail != NULL);
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
-	
+
 	tblname = kolab_mail_side_cache_sql_new_tblname (uid, foldername);
-	
+
 	/* check if object exists */
 	exists = kolab_util_sqlite_table_exists (kdb, tblname, &tmp_err);
 	if (tmp_err != NULL) {
@@ -399,7 +399,7 @@ kolab_mail_side_cache_sql_store_object (KolabUtilSqliteDb *kdb,
 		                           mpart->mime_type,
 		                           mpart->length);
 		ok = kolab_util_sqlite_prep_stmt (kdb, &sql_stmt, sql_str, &tmp_err);
-		sqlite3_free (sql_str);		
+		sqlite3_free (sql_str);
 		if (! ok)
 			break;
 		sql_errno = sqlite3_bind_blob (sql_stmt, 1, mpart->data, (int)(mpart->length), NULL);
@@ -414,7 +414,7 @@ kolab_mail_side_cache_sql_store_object (KolabUtilSqliteDb *kdb,
 			break;
 		}
 		continue;
-          sql_err:
+	sql_err:
 		g_set_error (&tmp_err,
 		             KOLAB_UTIL_ERROR,
 		             KOLAB_UTIL_ERROR_SQLITE_DB,
@@ -454,7 +454,7 @@ kolab_mail_side_cache_init (KolabMailSideCache *object)
 
 	self = KOLAB_MAIL_SIDE_CACHE (object);
 	priv = KOLAB_MAIL_SIDE_CACHE_PRIVATE (self);
-	
+
 	priv->ksettings = NULL;
 	priv->mimebuilder = NULL;
 	priv->is_up = FALSE;
@@ -469,7 +469,7 @@ kolab_mail_side_cache_dispose (GObject *object)
 
 	self = KOLAB_MAIL_SIDE_CACHE (object);
 	priv = KOLAB_MAIL_SIDE_CACHE_PRIVATE (self);
-	
+
 	if (priv->ksettings != NULL) { /* ref'd in configure() */
 		g_object_unref (priv->ksettings);
 		priv->ksettings = NULL;
@@ -516,7 +516,7 @@ kolab_mail_side_cache_configure  (KolabMailSideCache *self,
                                   GError **err)
 {
 	KolabMailSideCachePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SIDE_CACHE (self));
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (ksettings));
 	g_assert (KOLAB_IS_MAIL_MIME_BUILDER (mimebuilder));
@@ -542,7 +542,7 @@ kolab_mail_side_cache_bringup (KolabMailSideCache *self,
 	KolabMailSideCachePrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SIDE_CACHE (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -550,7 +550,7 @@ kolab_mail_side_cache_bringup (KolabMailSideCache *self,
 
 	if (priv->is_up == TRUE)
 		return TRUE;
-	
+
 	/* init sql db */
 	ok = kolab_util_backend_sqlite_db_new_open (&(priv->kdb),
 	                                            priv->ksettings,
@@ -572,7 +572,7 @@ kolab_mail_side_cache_shutdown (KolabMailSideCache *self,
 	KolabMailSideCachePrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SIDE_CACHE (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -580,7 +580,7 @@ kolab_mail_side_cache_shutdown (KolabMailSideCache *self,
 
 	if (priv->is_up == FALSE)
 		return TRUE;
-	
+
 	ok = kolab_util_sqlite_db_free (priv->kdb, &tmp_err);
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
@@ -600,19 +600,19 @@ kolab_mail_side_cache_query_foldernames (KolabMailSideCache *self,
                                          GError **err)
 {
 	KolabMailSideCachePrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SIDE_CACHE (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
 	priv = KOLAB_MAIL_SIDE_CACHE_PRIVATE (self);
 
 	g_assert (priv->is_up == TRUE);
-	
+
 	/* TODO implement me by SQLiteDB
 	 *
 	 * - need to list all folders known to SideCache
 	 * - this might be needed if we store new folders
-	 *   in the SideCache 
+	 *   in the SideCache
 	 * - as long as we create new folders only in
 	 *   online mode, this should never be needed
 	 */
@@ -628,7 +628,7 @@ kolab_mail_side_cache_delete_folder (KolabMailSideCache *self,
 	KolabMailSideCachePrivate *priv = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SIDE_CACHE (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -672,7 +672,7 @@ kolab_mail_side_cache_store (KolabMailSideCache *self,
 	priv = KOLAB_MAIL_SIDE_CACHE_PRIVATE (self);
 
 	g_assert (priv->is_up == TRUE);
-	
+
 	kolab_uid = kolab_mail_handle_get_uid (kmailhandle);
 	if (kolab_uid == NULL) {
 		g_set_error (err,
@@ -711,7 +711,7 @@ kolab_mail_side_cache_retrieve (KolabMailSideCache *self,
 	const gchar *foldername = NULL;
 	const gchar *kolab_uid = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SIDE_CACHE (self));
 	g_assert (KOLAB_IS_MAIL_HANDLE (kmailhandle));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -719,7 +719,7 @@ kolab_mail_side_cache_retrieve (KolabMailSideCache *self,
 	priv = KOLAB_MAIL_SIDE_CACHE_PRIVATE (self);
 
 	g_assert (priv->is_up == TRUE);
-	
+
 	kolab_uid = kolab_mail_handle_get_uid (kmailhandle);
 	if (kolab_uid == NULL) {
 		g_set_error (err,
@@ -778,7 +778,7 @@ kolab_mail_side_cache_delete_by_uid (KolabMailSideCache *self,
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
-	
+
 	priv = KOLAB_MAIL_SIDE_CACHE_PRIVATE (self);
 
 	g_assert (priv->is_up == TRUE);
@@ -805,7 +805,7 @@ kolab_mail_side_cache_delete (KolabMailSideCache *self,
 	const gchar *foldername = NULL;
 	gboolean ok = TRUE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SIDE_CACHE (self));
 	g_assert (KOLAB_IS_MAIL_HANDLE (kmailhandle));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
diff --git a/src/libekolab/kolab-mail-summary.c b/src/libekolab/kolab-mail-summary.c
index 5812b51..ba788ba 100644
--- a/src/libekolab/kolab-mail-summary.c
+++ b/src/libekolab/kolab-mail-summary.c
@@ -99,8 +99,8 @@ kolab_mail_summary_new_from_ecalcomponent (ECalComponent *ecalcomp)
 		ECalComponentText *ect = g_new0 (ECalComponentText, 1);
 		e_cal_component_get_summary (ecalcomp, ect);
 		kolab_mail_summary_set_char_field (summary,
-			                           KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_SUMMARY,
-			                           g_strdup (ect->value));
+		                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_SUMMARY,
+		                                   g_strdup (ect->value));
 		kolab_mail_summary_util_e_cal_component_free_text (ect);
 	}
 
@@ -108,8 +108,8 @@ kolab_mail_summary_new_from_ecalcomponent (ECalComponent *ecalcomp)
 		ECalComponentOrganizer *eco = g_new0 (ECalComponentOrganizer, 1);
 		e_cal_component_get_organizer (ecalcomp, eco);
 		kolab_mail_summary_set_char_field (summary,
-			                           KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_ORGANIZER,
-			                           g_strdup (eco->value));
+		                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_ORGANIZER,
+		                                   g_strdup (eco->value));
 		kolab_mail_summary_util_e_cal_component_free_organizer (eco);
 	}
 
@@ -117,16 +117,16 @@ kolab_mail_summary_new_from_ecalcomponent (ECalComponent *ecalcomp)
 		const gchar *ecl = NULL;
 		e_cal_component_get_location (ecalcomp, &ecl);
 		kolab_mail_summary_set_char_field (summary,
-			                           KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_LOCATION,
-			                           g_strdup (ecl));
+		                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_LOCATION,
+		                                   g_strdup (ecl));
 	}
 
 	{ /* CATEGORY */
 		const gchar *ecc = NULL;
 		e_cal_component_get_categories (ecalcomp, &ecc);
 		kolab_mail_summary_set_char_field (summary,
-			                           KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_CATEGORY,
-			                           g_strdup (ecc));
+		                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_CATEGORY,
+		                                   g_strdup (ecc));
 	}
 
 	{ /* DTSTART */
@@ -139,18 +139,18 @@ kolab_mail_summary_new_from_ecalcomponent (ECalComponent *ecalcomp)
 
 		if (dt != NULL) {
 			kolab_mail_summary_set_char_field (summary,
-							   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTSTART,
-					                   g_strdup (dt));
+			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTSTART,
+			                                   g_strdup (dt));
 			kolab_mail_summary_set_char_field (summary,
-							   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTSTART_TZID,
-					                   g_strdup (ecdt->tzid));
+			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTSTART_TZID,
+			                                   g_strdup (ecdt->tzid));
 		} else {
 			kolab_mail_summary_set_char_field (summary,
-							   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTSTART,
-				                           NULL);
+			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTSTART,
+			                                   NULL);
 			kolab_mail_summary_set_char_field (summary,
-							   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTSTART_TZID,
-				                           NULL);
+			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTSTART_TZID,
+			                                   NULL);
 		}
 		e_cal_component_free_datetime (ecdt);
 		g_free (ecdt);
@@ -166,18 +166,18 @@ kolab_mail_summary_new_from_ecalcomponent (ECalComponent *ecalcomp)
 
 		if (dt != NULL) {
 			kolab_mail_summary_set_char_field (summary,
-							   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTEND,
-					                   g_strdup (dt));
+			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTEND,
+			                                   g_strdup (dt));
 			kolab_mail_summary_set_char_field (summary,
-							   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTEND_TZID,
-					                   g_strdup (ecdt->tzid));
+			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTEND_TZID,
+			                                   g_strdup (ecdt->tzid));
 		} else {
 			kolab_mail_summary_set_char_field (summary,
-							   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTEND,
-				                           NULL);
+			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTEND,
+			                                   NULL);
 			kolab_mail_summary_set_char_field (summary,
-							   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTEND_TZID,
-				                           NULL);
+			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_E_DTEND_TZID,
+			                                   NULL);
 		}
 		e_cal_component_free_datetime (ecdt);
 		g_free (ecdt);
@@ -212,13 +212,13 @@ kolab_mail_summary_new_from_ecalcomponent (ECalComponent *ecalcomp)
 
 		if (ecp != NULL) {
 			kolab_mail_summary_set_int_field (summary,
-				                          KOLAB_MAIL_SUMMARY_INT_FIELD_E_PRIORITY,
-				                          *ecp);
+			                                  KOLAB_MAIL_SUMMARY_INT_FIELD_E_PRIORITY,
+			                                  *ecp);
 			e_cal_component_free_priority (ecp);
 		} else {
 			kolab_mail_summary_set_int_field (summary,
-				                          KOLAB_MAIL_SUMMARY_INT_FIELD_E_PRIORITY,
-				                          0);
+			                                  KOLAB_MAIL_SUMMARY_INT_FIELD_E_PRIORITY,
+			                                  0);
 		}
 	}
 
@@ -228,13 +228,13 @@ kolab_mail_summary_new_from_ecalcomponent (ECalComponent *ecalcomp)
 
 		if (epc != NULL) {
 			kolab_mail_summary_set_int_field (summary,
-				                          KOLAB_MAIL_SUMMARY_INT_FIELD_E_PERCENT,
-				                          *epc);
+			                                  KOLAB_MAIL_SUMMARY_INT_FIELD_E_PERCENT,
+			                                  *epc);
 			e_cal_component_free_percent (epc);
 		} else {
 			kolab_mail_summary_set_int_field (summary,
-				                          KOLAB_MAIL_SUMMARY_INT_FIELD_E_PERCENT,
-				                          0);
+			                                  KOLAB_MAIL_SUMMARY_INT_FIELD_E_PERCENT,
+			                                  0);
 		}
 	}
 
@@ -316,12 +316,12 @@ kolab_mail_summary_new_from_econtact (EContact *econtact)
 			gp = e_contact_get_const (econtact, evo_field_ids[ii]);
 			if (gp != NULL)
 				kolab_mail_summary_set_char_field (summary,
-					                           sum_field_ids[ii],
-					                           g_strdup ((const gchar*)gp));
+				                                   sum_field_ids[ii],
+				                                   g_strdup ((const gchar*)gp));
 			else
 				kolab_mail_summary_set_char_field (summary,
-					                           sum_field_ids[ii],
-					                           NULL);
+				                                   sum_field_ids[ii],
+				                                   NULL);
 		}
 	}
 
diff --git a/src/libekolab/kolab-mail-synchronizer.c b/src/libekolab/kolab-mail-synchronizer.c
index e2f97fa..2408e11 100644
--- a/src/libekolab/kolab-mail-synchronizer.c
+++ b/src/libekolab/kolab-mail-synchronizer.c
@@ -12,12 +12,12 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
@@ -83,7 +83,7 @@ kolab_mail_synchronizer_init (KolabMailSynchronizer *object)
 
 	self = object;
 	priv = KOLAB_MAIL_SYNCHRONIZER_PRIVATE (self);
-	
+
 	priv->ksettings = NULL;
 	priv->is_up = FALSE;
 
@@ -101,7 +101,7 @@ kolab_mail_synchronizer_dispose (GObject *object)
 
 	self = KOLAB_MAIL_SYNCHRONIZER (object);
 	priv = KOLAB_MAIL_SYNCHRONIZER_PRIVATE (self);
-	
+
 	if (priv->client != NULL)
 		g_object_unref (priv->client);
 
@@ -134,7 +134,7 @@ kolab_mail_synchronizer_finalize (GObject *object)
 
 	self = KOLAB_MAIL_SYNCHRONIZER (object);
 	priv = KOLAB_MAIL_SYNCHRONIZER_PRIVATE (self);
-	
+
 	/* TODO: Add deinitalization code here */
 
 	G_OBJECT_CLASS (kolab_mail_synchronizer_parent_class)->finalize (object);
@@ -169,7 +169,7 @@ kolab_mail_synchronizer_get_foldertype (KolabMailSynchronizer *self,
 	KolabFolderSummary *info_summary = NULL;
 	KolabFolderSummary *imap_summary = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	/* info_fn may be NULL */
 	/* imap_fn may be NULL */
@@ -212,25 +212,25 @@ kolab_mail_synchronizer_get_foldertype (KolabMailSynchronizer *self,
 
 	if (info_summary != NULL)
 		info_folder_type = kolab_folder_summary_get_uint_field (info_summary,
-		                                                        KOLAB_FOLDER_SUMMARY_UINT_FIELD_FOLDER_TYPE);	
+		                                                        KOLAB_FOLDER_SUMMARY_UINT_FIELD_FOLDER_TYPE);
 	if (imap_summary != NULL)
 		imap_folder_type =  kolab_folder_summary_get_uint_field (imap_summary,
 		                                                         KOLAB_FOLDER_SUMMARY_UINT_FIELD_FOLDER_TYPE);
 
 	if ((imap_folder_type != KOLAB_FOLDER_TYPE_INVAL) &&
 	    (info_folder_type != KOLAB_FOLDER_TYPE_INVAL)) {
-		    if (imap_folder_type != info_folder_type) {
-			    g_warning ("%s: Folder (%s) InfoDb/ImapClient folder type mismatch: (%u)/(%u)",
-			               __func__, info_fn, info_folder_type, imap_folder_type);
-		    }
-		    /* TODO InfoDb folder type information not matching the ImapClient
-		     *      information may mean that the folder was deleted on server
-		     *      and re-created by the same name but with a different folder
-		     *      type. While this is a corner case, we do need to take care
-		     *      of it
-		     */
-	}
-	
+		if (imap_folder_type != info_folder_type) {
+			g_warning ("%s: Folder (%s) InfoDb/ImapClient folder type mismatch: (%u)/(%u)",
+			           __func__, info_fn, info_folder_type, imap_folder_type);
+		}
+		/* TODO InfoDb folder type information not matching the ImapClient
+		 *      information may mean that the folder was deleted on server
+		 *      and re-created by the same name but with a different folder
+		 *      type. While this is a corner case, we do need to take care
+		 *      of it
+		 */
+	}
+
 	/* TODO do proper merging here / check overwrite sequence
 	 *      (compare with finding final_fn in
 	 *      kolab_mail_synchronizer_folders_update_summary())
@@ -240,11 +240,11 @@ kolab_mail_synchronizer_get_foldertype (KolabMailSynchronizer *self,
 
 	if (info_folder_type != KOLAB_FOLDER_TYPE_INVAL)
 		folder_type = info_folder_type;
-	
+
 	if (folder_type == KOLAB_FOLDER_TYPE_INVAL)
 		folder_type = KOLAB_FOLDER_TYPE_UNKNOWN;
 
-skip:
+ skip:
 	if (info_summary != NULL)
 		kolab_folder_summary_free (info_summary);
 	if (imap_summary != NULL)
@@ -268,7 +268,7 @@ kolab_mail_synchronizer_get_uidvalidity (KolabMailSynchronizer *self,
 	guint64 info_uidvalidity = 0;
 	guint64 imap_uidvalidity = 0;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	/* info_fn may be NULL */
 	/* imap_fn may be NULL */
@@ -281,7 +281,7 @@ kolab_mail_synchronizer_get_uidvalidity (KolabMailSynchronizer *self,
 	/* TODO Take care of situation where both folders
 	 *      do not exist (can this happen?)
 	 */
-	
+
 	if (info_fn != NULL) {
 		KolabFolderSummary *summary = NULL;
 		summary = kolab_mail_info_db_query_folder_summary (priv->infodb,
@@ -295,7 +295,7 @@ kolab_mail_synchronizer_get_uidvalidity (KolabMailSynchronizer *self,
 		}
 		if (summary != NULL) {
 			info_uidvalidity = kolab_folder_summary_get_uint64_field (summary,
-				                                                  KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY);
+			                                                          KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY);
 			kolab_folder_summary_free (summary);
 		} else {
 			info_uidvalidity = 0;
@@ -315,7 +315,7 @@ kolab_mail_synchronizer_get_uidvalidity (KolabMailSynchronizer *self,
 		}
 		if (summary != NULL) {
 			imap_uidvalidity = kolab_folder_summary_get_uint64_field (summary,
-				                                                  KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY);
+			                                                          KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY);
 			kolab_folder_summary_free (summary);
 		} else {
 			imap_uidvalidity = 0;
@@ -331,7 +331,7 @@ kolab_mail_synchronizer_get_uidvalidity (KolabMailSynchronizer *self,
 	g_debug ("%s: InfoDb (%s) ImapClient (%s) UIDVALIDITY (%lld)",
 	         __func__, info_fn, imap_fn, uidvalidity);
 
-skip:
+ skip:
 	if (tmp_err != NULL) {
 		g_propagate_error (err, tmp_err);
 		return 0;
@@ -352,7 +352,7 @@ kolab_mail_synchronizer_folders_uidvalidity_changed (KolabMailSynchronizer *self
 	                                              KOLAB_FOLDER_SUMMARY_UINT_FIELD_CACHE_STATUS);
 	if (status & KOLAB_OBJECT_CACHE_STATUS_CHANGED)
 		return TRUE;
-	
+
 	return FALSE;
 }
 
@@ -370,7 +370,7 @@ kolab_mail_synchronizer_folders_clear_changed (KolabMailSynchronizer *self,
 	                                              KOLAB_FOLDER_SUMMARY_UINT_FIELD_CACHE_STATUS);
 	uidvalidity = kolab_folder_summary_get_uint64_field (summary,
 	                                                     KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY);
-	
+
 	status = status & (~(guint)KOLAB_OBJECT_CACHE_STATUS_CHANGED);
 
 	kolab_folder_summary_set_uint_field (summary,
@@ -400,17 +400,17 @@ kolab_mail_synchronizer_folders_update_summary (KolabMailSynchronizer *self,
 	const gchar *final_fn = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE);
 	/* info_fn may be NULL */
 	/* imap_fn may be NULL */
 	/* side_fn may be NULL */
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
-	
+
 	priv = KOLAB_MAIL_SYNCHRONIZER_PRIVATE (self);
 
-	/* TODO 
+	/* TODO
 	 *
 	 * KOLAB_MAIL_ACCESS_OPMODE_OFFLINE
 	 * - sync-op is sanity-checking only (reality-check)
@@ -426,8 +426,8 @@ kolab_mail_synchronizer_folders_update_summary (KolabMailSynchronizer *self,
 	 *     (taken care of per-uid)
 	 *   - folder removal
 	 */
-	
-	/* TODO check overwrite sequence 
+
+	/* TODO check overwrite sequence
 	 *      (in which other places do we do that?)
 	 */
 	final_fn = info_fn;
@@ -451,9 +451,9 @@ kolab_mail_synchronizer_folders_update_summary (KolabMailSynchronizer *self,
 		g_assert (g_strcmp0 (final_fn, imap_fn) == 0);
 	if (side_fn != NULL)
 		g_assert (g_strcmp0 (final_fn, side_fn) == 0);
-	
+
 	/* aggregate folder information */
-	
+
 	/* cache location */
 	if (imap_fn != NULL)
 		location |= KOLAB_OBJECT_CACHE_LOCATION_IMAP;
@@ -488,9 +488,9 @@ kolab_mail_synchronizer_folders_update_summary (KolabMailSynchronizer *self,
 	/* folder uidvalidity change (only in online mode) */
 	if (opmode > KOLAB_MAIL_ACCESS_OPMODE_OFFLINE) {
 		uidval_srv = kolab_mail_synchronizer_get_uidvalidity (self,
-			                                              info_fn,
-			                                              imap_fn,
-			                                              &tmp_err);
+		                                                      info_fn,
+		                                                      imap_fn,
+		                                                      &tmp_err);
 		if (tmp_err != NULL) {
 			g_propagate_error (err, tmp_err);
 			return FALSE;
@@ -529,21 +529,21 @@ kolab_mail_synchronizer_folders_update_summary (KolabMailSynchronizer *self,
 	/* update uidvalidity summary data (only in online mode) */
 	if (opmode > KOLAB_MAIL_ACCESS_OPMODE_OFFLINE) {
 		status = kolab_folder_summary_get_uint_field (summary,
-			                                      KOLAB_FOLDER_SUMMARY_UINT_FIELD_CACHE_STATUS);
+		                                              KOLAB_FOLDER_SUMMARY_UINT_FIELD_CACHE_STATUS);
 		uidval_sum = kolab_folder_summary_get_uint64_field (summary,
-			                                            KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY);
+		                                                    KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY);
 		if (uidval_sum != uidval_srv)
 			status |= KOLAB_OBJECT_CACHE_STATUS_CHANGED;
 
 		kolab_folder_summary_set_uint_field (summary,
-			                             KOLAB_FOLDER_SUMMARY_UINT_FIELD_CACHE_STATUS,
-			                             status);
+		                                     KOLAB_FOLDER_SUMMARY_UINT_FIELD_CACHE_STATUS,
+		                                     status);
 		kolab_folder_summary_set_uint64_field (summary,
-			                               KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY,
-			                               uidval_srv);
+		                                       KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY,
+		                                       uidval_srv);
 		kolab_folder_summary_set_uint64_field (summary,
-			                               KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY_SYNC,
-			                               uidval_sum);
+		                                       KOLAB_FOLDER_SUMMARY_UINT64_FIELD_UIDVALIDITY_SYNC,
+		                                       uidval_sum);
 	}
 
 	/* update InfoDb with new folder summary data */
@@ -571,7 +571,7 @@ kolab_mail_synchronizer_folders_update_walk (KolabMailSynchronizer *self,
 	KolabMailSynchronizerPrivate *priv = NULL;
 	GList *lst_ptr = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE);
 	g_assert (walk_id < KOLAB_MAIL_SYNCHRONIZER_FOLDER_LAST_WALK);
@@ -590,34 +590,34 @@ kolab_mail_synchronizer_folders_update_walk (KolabMailSynchronizer *self,
 		gboolean ok = FALSE;
 
 		switch (walk_id) {
-			case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_INFO:
-				info_fn = (const gchar *)(lst_ptr->data);
-				if (imap_folders_tbl != NULL)
-					imap_fn = g_hash_table_lookup (imap_folders_tbl, info_fn);
-				if (side_folders_tbl != NULL)
-					side_fn = g_hash_table_lookup (side_folders_tbl, info_fn);
-				if ((imap_fn == NULL) && (side_fn == NULL)) {
-					/* folder does no longer exist */
-					ok = kolab_mail_info_db_remove_folder (priv->infodb,
-					                                       info_fn,
-					                                       &tmp_err);
-					if (! ok) {
-						g_propagate_error (err, tmp_err);
-						return FALSE;
-					}
-					goto folder_skip;
+		case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_INFO:
+			info_fn = (const gchar *)(lst_ptr->data);
+			if (imap_folders_tbl != NULL)
+				imap_fn = g_hash_table_lookup (imap_folders_tbl, info_fn);
+			if (side_folders_tbl != NULL)
+				side_fn = g_hash_table_lookup (side_folders_tbl, info_fn);
+			if ((imap_fn == NULL) && (side_fn == NULL)) {
+				/* folder does no longer exist */
+				ok = kolab_mail_info_db_remove_folder (priv->infodb,
+				                                       info_fn,
+				                                       &tmp_err);
+				if (! ok) {
+					g_propagate_error (err, tmp_err);
+					return FALSE;
 				}
-				break;
-			case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_IMAP:
-				imap_fn = (const gchar *)(lst_ptr->data);
-				if (side_folders_tbl != NULL)
-					side_fn = g_hash_table_lookup (side_folders_tbl, imap_fn);
-				break;
-			case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_SIDE:
-				side_fn = (const gchar *)(lst_ptr->data);
-				break;
-			default:
-				g_assert_not_reached ();
+				goto folder_skip;
+			}
+			break;
+		case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_IMAP:
+			imap_fn = (const gchar *)(lst_ptr->data);
+			if (side_folders_tbl != NULL)
+				side_fn = g_hash_table_lookup (side_folders_tbl, imap_fn);
+			break;
+		case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_SIDE:
+			side_fn = (const gchar *)(lst_ptr->data);
+			break;
+		default:
+			g_assert_not_reached ();
 		}
 
 		ok = kolab_mail_synchronizer_folders_update_summary (self,
@@ -632,21 +632,21 @@ kolab_mail_synchronizer_folders_update_walk (KolabMailSynchronizer *self,
 		}
 
 		switch (walk_id) {
-			case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_INFO:
-				if (imap_fn != NULL)
-					g_hash_table_remove (imap_folders_tbl,
-					                     imap_fn);
-				/* no break */
-			case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_IMAP:
-				if (side_fn != NULL)
-					g_hash_table_remove (side_folders_tbl,
-					                     side_fn);
-				/* no break */
-			case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_SIDE:
-			default:
-				{ /* nop */ }
+		case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_INFO:
+			if (imap_fn != NULL)
+				g_hash_table_remove (imap_folders_tbl,
+				                     imap_fn);
+			/* no break */
+		case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_IMAP:
+			if (side_fn != NULL)
+				g_hash_table_remove (side_folders_tbl,
+				                     side_fn);
+			/* no break */
+		case KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_SIDE:
+		default:
+			{ /* nop */ }
 		}
-		
+
 	folder_skip:
 		lst_ptr = g_list_next (lst_ptr);
 	}
@@ -666,7 +666,7 @@ kolab_mail_synchronizer_folders_update_infodb (KolabMailSynchronizer *self,
 	GHashTable *side_folders_tbl = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -690,7 +690,7 @@ kolab_mail_synchronizer_folders_update_infodb (KolabMailSynchronizer *self,
 	side_folders_tbl = kolab_util_glib_ghashtable_new_from_str_glist (tmp_lst);
 	kolab_util_glib_glist_free (tmp_lst);
 	tmp_lst = NULL;
-	
+
 	/* get InfoDb folders */
 	info_folders_lst = kolab_mail_info_db_query_foldernames (priv->infodb,
 	                                                         &tmp_err);
@@ -714,35 +714,35 @@ kolab_mail_synchronizer_folders_update_infodb (KolabMailSynchronizer *self,
 	if (imap_folders_tbl != NULL) {
 		tmp_lst = g_hash_table_get_keys (imap_folders_tbl);
 		ok = kolab_mail_synchronizer_folders_update_walk (self,
-				                                  opmode,
-				                                  KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_IMAP,
-				                                  tmp_lst,
-				                                  imap_folders_tbl,
-				                                  side_folders_tbl,
-				                                  &tmp_err);
+		                                                  opmode,
+		                                                  KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_IMAP,
+		                                                  tmp_lst,
+		                                                  imap_folders_tbl,
+		                                                  side_folders_tbl,
+		                                                  &tmp_err);
 		g_list_free (tmp_lst);
 		tmp_lst = NULL;
 		if (! ok)
 			goto skip;
 	}
-	
+
 	/* walk through remaining SideCache folders list */
 	if (side_folders_tbl != NULL) {
 		tmp_lst = g_hash_table_get_keys (side_folders_tbl);
 		ok = kolab_mail_synchronizer_folders_update_walk (self,
-			                                          opmode,
-			                                          KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_SIDE,
-			                                          tmp_lst,
-			                                          imap_folders_tbl,
-			                                          side_folders_tbl,
-			                                          &tmp_err);
+		                                                  opmode,
+		                                                  KOLAB_MAIL_SYNCHRONIZER_FOLDER_WALK_SIDE,
+		                                                  tmp_lst,
+		                                                  imap_folders_tbl,
+		                                                  side_folders_tbl,
+		                                                  &tmp_err);
 		g_list_free (tmp_lst);
 		tmp_lst = NULL;
 		if (! ok)
 			goto skip;
 	}
 
-skip:
+ skip:
 	if (imap_folders_tbl != NULL)
 		g_hash_table_destroy (imap_folders_tbl);
 	if (side_folders_tbl != NULL)
@@ -806,7 +806,7 @@ kolab_mail_synchronizer_uid_combine_all (KolabMailSynchronizer *self,
 			(void)g_hash_table_remove (client_uids_tbl, uid);
 			uids_lst_ptr = g_list_next (uids_lst_ptr);
 		}
-		tmp_lst = g_hash_table_get_keys (client_uids_tbl); /* may be NULL */		
+		tmp_lst = g_hash_table_get_keys (client_uids_tbl); /* may be NULL */
 	}
 
 	/* merge the two UID lists into one */
@@ -820,7 +820,7 @@ kolab_mail_synchronizer_uid_combine_all (KolabMailSynchronizer *self,
 		g_list_free (tmp_lst);
 	if (client_uids_tbl != NULL)
 		g_hash_table_destroy (client_uids_tbl);
-	
+
 	return uids_lst;
 }
 
@@ -842,7 +842,7 @@ kolab_mail_synchronizer_record_update_info (KolabMailSynchronizer *self,
 	const gchar *imapuid_client = NULL;
 	gboolean do_set_changed_flag = FALSE; /* initial FALSE needed ! */
 	gboolean do_imap_uid_update = FALSE; /* initial FALSE needed ! */
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert ((opmode > KOLAB_MAIL_ACCESS_OPMODE_CONFIGURED) &&
 	          (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE));
@@ -860,33 +860,33 @@ kolab_mail_synchronizer_record_update_info (KolabMailSynchronizer *self,
 		record->summary = kolab_mail_summary_clone (imap_summary);
 	if (record->summary == NULL)
 		record->summary = kolab_mail_summary_new ();
-	
+
 	kolab_mail_summary_set_char_field (record->summary,
-		                           KOLAB_MAIL_SUMMARY_CHAR_FIELD_KOLAB_UID,
-		                           g_strdup (uid));
+	                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_KOLAB_UID,
+	                                   g_strdup (uid));
 	kolab_mail_summary_set_uint_field (record->summary,
-		                           KOLAB_MAIL_SUMMARY_UINT_FIELD_FOLDER_CONTEXT,
-		                           folder_context);
+	                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_FOLDER_CONTEXT,
+	                                   folder_context);
 	kolab_mail_summary_set_uint_field (record->summary,
-		                           KOLAB_MAIL_SUMMARY_UINT_FIELD_FOLDER_TYPE,
-		                           folder_type);
+	                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_FOLDER_TYPE,
+	                                   folder_type);
 
 	if (imap_summary == NULL) {
 		/* object has been deleted from ImapCache */
 		location = kolab_mail_summary_get_uint_field (record->summary,
-			                                      KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION);
+		                                              KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION);
 		location &= ~((guint)KOLAB_OBJECT_CACHE_LOCATION_IMAP);
 		kolab_mail_summary_set_uint_field (record->summary,
 		                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
 		                                   location);
 		imapuid_client = kolab_mail_summary_get_char_field (record->summary,
-						                    KOLAB_MAIL_SUMMARY_CHAR_FIELD_IMAP_UID);
+		                                                    KOLAB_MAIL_SUMMARY_CHAR_FIELD_IMAP_UID);
 	} else {
 		gint ii = 0;
 		gboolean tmp = FALSE;
 		/* get current ImapClient IMAP UID (to be checked for change) */
 		imapuid_client = kolab_mail_summary_get_char_field (imap_summary,
-						                    KOLAB_MAIL_SUMMARY_CHAR_FIELD_IMAP_UID);
+		                                                    KOLAB_MAIL_SUMMARY_CHAR_FIELD_IMAP_UID);
 		/* update InfoDbRecord non-EDS data from IMAP summary */
 		tmp = kolab_mail_summary_get_bool_field (imap_summary,
 		                                         KOLAB_MAIL_SUMMARY_BOOL_FIELD_COMPLETE);
@@ -919,7 +919,7 @@ kolab_mail_synchronizer_record_update_info (KolabMailSynchronizer *self,
 	if (uidval_changed) {
 		/* in case of folder uidvalidity change, we mark the
 		 * object as changed and store the new IMAP UID (the old one
-		 * does us no good any longer)	                                               
+		 * does us no good any longer)
 		 */
 		do_set_changed_flag = TRUE;
 		do_imap_uid_update = TRUE;
@@ -927,8 +927,8 @@ kolab_mail_synchronizer_record_update_info (KolabMailSynchronizer *self,
 	}
 
 	imapuid_sync = kolab_mail_info_db_record_get_char_field (record,
-		                                                 KOLAB_MAIL_INFO_DB_RECORD_CHAR_FIELD_IMAP_UID_SYNC);
-	
+	                                                         KOLAB_MAIL_INFO_DB_RECORD_CHAR_FIELD_IMAP_UID_SYNC);
+
 	if (imapuid_sync == NULL) {
 		/* we've never seen this imap uid before, so we store
 		 * it but do not mark the object as 'changed' (this
@@ -948,7 +948,7 @@ kolab_mail_synchronizer_record_update_info (KolabMailSynchronizer *self,
 		do_imap_uid_update = TRUE;
 		goto check_skip;
 	}
-	
+
 	if (g_strcmp0 (imapuid_client, imapuid_sync) != 0) {
 		/* we have an old imap uid stored, but the one
 		 * reported from the ImapClient differs. this
@@ -960,24 +960,24 @@ kolab_mail_synchronizer_record_update_info (KolabMailSynchronizer *self,
 		do_imap_uid_update = TRUE;
 	}
 
-check_skip:
-	
+ check_skip:
+
 	/* the following is skipped in offline mode */
 	if (do_set_changed_flag) {
 		status = kolab_mail_summary_get_uint_field (record->summary,
-				                            KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
+		                                            KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
 		status |= KOLAB_OBJECT_CACHE_STATUS_CHANGED;
 		kolab_mail_summary_set_uint_field (record->summary,
-			                           KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS,
-			                           status);
+		                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS,
+		                                   status);
 	}
 	if (do_imap_uid_update) {
 		kolab_mail_summary_set_char_field (record->summary,
 		                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_IMAP_UID,
 		                                   g_strdup (imapuid_client));
 		kolab_mail_info_db_record_set_char_field (record,
-			                                  KOLAB_MAIL_INFO_DB_RECORD_CHAR_FIELD_IMAP_UID_SYNC,
-			                                  g_strdup (imapuid_client));
+		                                          KOLAB_MAIL_INFO_DB_RECORD_CHAR_FIELD_IMAP_UID_SYNC,
+		                                          g_strdup (imapuid_client));
 	}
 }
 
@@ -1003,7 +1003,7 @@ kolab_mail_synchronizer_uids_infosync (KolabMailSynchronizer *self,
 	g_assert (foldername != NULL);
 	g_assert (folder_summary != NULL);
 	g_assert (uids_lst != NULL);
-	
+
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
 	priv = KOLAB_MAIL_SYNCHRONIZER_PRIVATE (self);
@@ -1081,9 +1081,9 @@ kolab_mail_synchronizer_uids_infosync (KolabMailSynchronizer *self,
 		kolab_mail_info_db_record_free (record_orig);
 		if (! records_eq) {
 			ok = kolab_mail_info_db_update_record (priv->infodb,
-							       record,
-							       foldername,
-							       &tmp_err);
+			                                       record,
+			                                       foldername,
+			                                       &tmp_err);
 		}
 	uid_skip:
 		if (record != NULL)
@@ -1108,7 +1108,7 @@ kolab_mail_synchronizer_uids_update_infodb (KolabMailSynchronizer *self,
 	GList *folders_lst = NULL;
 	GList *folders_lst_ptr = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE);
 	/* foldername may be NULL */
@@ -1125,7 +1125,7 @@ kolab_mail_synchronizer_uids_update_infodb (KolabMailSynchronizer *self,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	if (foldername != NULL) {
 		GHashTable *folders_tbl = NULL;
 		gchar *fn = NULL;
@@ -1144,7 +1144,7 @@ kolab_mail_synchronizer_uids_update_infodb (KolabMailSynchronizer *self,
 			             __func__, foldername);
 			return FALSE;
 		}
-		
+
 		folders_lst = g_list_prepend (folders_lst, g_strdup (fn));
 		g_hash_table_destroy (folders_tbl);
 	}
@@ -1162,10 +1162,10 @@ kolab_mail_synchronizer_uids_update_infodb (KolabMailSynchronizer *self,
 		foldername = (const gchar*)(folders_lst_ptr->data);
 
 		imap_summaries_tbl = kolab_mail_imap_client_query_summaries (priv->client,
-			                                                     foldername,
-			                                                     NULL,
+		                                                             foldername,
+		                                                             NULL,
 		                                                             TRUE, /* do folder update */
-			                                                     &tmp_err);
+		                                                             &tmp_err);
 		if (tmp_err != NULL)
 			goto folder_skip;
 
@@ -1209,8 +1209,8 @@ kolab_mail_synchronizer_uids_update_infodb (KolabMailSynchronizer *self,
 			kolab_mail_synchronizer_folders_clear_changed (self,
 			                                               folder_summary);
 			ok = kolab_mail_info_db_update_folder_summary (priv->infodb,
-					                               folder_summary,
-					                               &tmp_err);
+			                                               folder_summary,
+			                                               &tmp_err);
 			if (! ok)
 				goto folder_skip;
 		}
@@ -1228,7 +1228,7 @@ kolab_mail_synchronizer_uids_update_infodb (KolabMailSynchronizer *self,
 		}
 		folders_lst_ptr = g_list_next (folders_lst_ptr);
 	}
-	
+
 	kolab_util_glib_glist_free (folders_lst);
 
 	return TRUE;
@@ -1243,21 +1243,21 @@ kolab_mail_synchronizer_new_free_uid (KolabMailSynchronizer *self,
 	KolabMailSummary *summary = NULL;
 	gchar *changed_uid = NULL;
 	gchar *uid = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	/* summaries may be NULL */
 	/* changed_uids may be NULL */
 
 	priv = KOLAB_MAIL_SYNCHRONIZER_PRIVATE (self);
-	
+
 	g_assert (priv->is_up == TRUE);
 
 	/* TODO if deleted uids are held in a separate list,
 	 *      take care of it here as well
 	 */
-	
+
 	uid = e_cal_component_gen_uid ();
-	
+
 	if ((summaries == NULL) && (changed_uids == NULL))
 		return uid;
 
@@ -1321,7 +1321,7 @@ kolab_mail_synchronizer_act_on_econtact (EContact *econtact_loc,
 		           __func__, uid, foldername);
 		return FALSE;
 	}
-	
+
 	itt_srv = icaltime_from_string (modtime_srv);
 	if (icaltime_is_null_time (itt_srv)) {
 		/* TODO extract ical error number and message */
@@ -1335,7 +1335,7 @@ kolab_mail_synchronizer_act_on_econtact (EContact *econtact_loc,
 		can_act = TRUE; /* local is newer */
 	else
 		can_act = FALSE; /* same, or server is newer */
-	
+
 	return can_act;
 }
 
@@ -1353,7 +1353,7 @@ kolab_mail_synchronizer_act_on_ecalcomp (ECalComponent *ecalcomp_loc,
 	g_assert (E_IS_CAL_COMPONENT (ecalcomp_srv));
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
-	
+
 	/* get the modification times from the objects */
 	e_cal_component_get_last_modified (ecalcomp_loc, &lm_itt_loc);
 	e_cal_component_get_last_modified (ecalcomp_srv, &lm_itt_srv);
@@ -1393,7 +1393,7 @@ kolab_mail_synchronizer_act_on_ecalcomp (ECalComponent *ecalcomp_loc,
 		can_act = TRUE; /* local is newer */
 	else
 		can_act = FALSE; /* same, or server is newer */
-	
+
 	return can_act;
 }
 
@@ -1409,7 +1409,7 @@ kolab_mail_synchronizer_handle_new_from_record (KolabMailSynchronizer *self,
 	KolabMailSummary *summary = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
@@ -1419,7 +1419,7 @@ kolab_mail_synchronizer_handle_new_from_record (KolabMailSynchronizer *self,
 	priv = KOLAB_MAIL_SYNCHRONIZER_PRIVATE (self);
 
 	summary = kolab_mail_summary_clone (record->summary);
-	
+
 	if (summary == NULL)
 		/* UID has never been stored before */
 		return NULL;
@@ -1435,8 +1435,8 @@ kolab_mail_synchronizer_handle_new_from_record (KolabMailSynchronizer *self,
 		g_propagate_error (err, tmp_err);
 		return NULL;
 	}
-	
-	return local_handle;	
+
+	return local_handle;
 }
 
 static gboolean
@@ -1449,7 +1449,7 @@ kolab_mail_synchronizer_push_sidecache (KolabMailSynchronizer *self,
 	GList *uids_lst = NULL;
 	GList *uids_lst_ptr = NULL;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert (foldername != NULL);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -1514,14 +1514,14 @@ kolab_mail_synchronizer_push_sidecache (KolabMailSynchronizer *self,
 		location = kolab_mail_summary_get_uint_field (record->summary,
 		                                              KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION);
 		status = kolab_mail_summary_get_uint_field (record->summary,
-			                                    KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
+		                                            KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
 
 		/* if the object is in SideCache and not deleted, retrieve it */
 		if ((location & (guint)KOLAB_OBJECT_CACHE_LOCATION_SIDE) &&
 		    (!(status & (guint)KOLAB_OBJECT_CACHE_STATUS_DELETED))) {
 			ok = kolab_mail_side_cache_retrieve (priv->sidecache,
-					                     kmailhandle,
-					                     &tmp_err);
+			                                     kmailhandle,
+			                                     &tmp_err);
 			if (! ok) {
 				if (tmp_err->code != KOLAB_BACKEND_ERROR_NOTFOUND) {
 					goto uid_cleanup;
@@ -1537,12 +1537,12 @@ kolab_mail_synchronizer_push_sidecache (KolabMailSynchronizer *self,
 				tmp_err = NULL;
 				location = location & (~location_side);
 				kolab_mail_summary_set_uint_field (record->summary,
-					                           KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
-					                           location);
+				                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
+				                                   location);
 				ok = kolab_mail_info_db_update_record (priv->infodb,
-					                               record,
-					                               foldername,
-					                               &tmp_err);
+				                                       record,
+				                                       foldername,
+				                                       &tmp_err);
 				if (! ok)
 					goto uid_cleanup;
 			}
@@ -1562,19 +1562,19 @@ kolab_mail_synchronizer_push_sidecache (KolabMailSynchronizer *self,
 
 		/* store transaction start */
 		ok = kolab_mail_synchronizer_transaction_start (self,
-			                                        KOLAB_MAIL_ACCESS_OPMODE_ONLINE,
-			                                        KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_PUSH,
-			                                        kmailhandle,
-			                                        foldername,
+		                                                KOLAB_MAIL_ACCESS_OPMODE_ONLINE,
+		                                                KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_PUSH,
+		                                                kmailhandle,
+		                                                foldername,
 		                                                record,
-			                                        &tmp_err);
+		                                                &tmp_err);
 		if (tmp_err != NULL)
 			goto uid_cleanup;
 
 		if (do_act) {
 			/* status bit may have been changed by transaction function, re-read it */
 			status = kolab_mail_summary_get_uint_field (record->summary,
-				                                    KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
+			                                            KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
 			if (status & (guint)KOLAB_OBJECT_CACHE_STATUS_DELETED) {
 				if (! (status & KOLAB_OBJECT_CACHE_STATUS_CHANGED)) {
 					/* Delete on the server only if the object is unchanged.
@@ -1584,46 +1584,46 @@ kolab_mail_synchronizer_push_sidecache (KolabMailSynchronizer *self,
 					 * with Kontact reference behaviour)
 					 */
 					ok = kolab_mail_imap_client_delete (priv->client,
-						                            kmailhandle,
+					                                    kmailhandle,
 					                                    TRUE, /* try only IMAP UID */
 					                                    FALSE, /* folder already updated */
-						                            &tmp_err);
+					                                    &tmp_err);
 				} else {
 					ok = TRUE;
 				}
 			} else {
 				ok = kolab_mail_imap_client_store (priv->client,
-						                   kmailhandle,
-						                   foldername,
+				                                   kmailhandle,
+				                                   foldername,
 				                                   FALSE, /* folder already updated */
-						                   &tmp_err);
+				                                   &tmp_err);
 			}
 		} else {
 			g_debug ("%s: UID (%s) Folder (%s) not pushed to / deleted from server due to selected sync strategy",
 			         __func__, uid, foldername);
 		}
-		
+
 		summary = kolab_mail_handle_get_summary_nonconst (kmailhandle);
 		g_assert (summary != NULL);
 		kolab_mail_summary_set_bool_field (summary,
-				                   KOLAB_MAIL_SUMMARY_BOOL_FIELD_COMPLETE,
-				                   FALSE);
+		                                   KOLAB_MAIL_SUMMARY_BOOL_FIELD_COMPLETE,
+		                                   FALSE);
 		if (ok)
 			ok = kolab_mail_synchronizer_transaction_commit (self,
-				                                         KOLAB_MAIL_ACCESS_OPMODE_ONLINE,
-				                                         KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_PUSH,
-				                                         kmailhandle,
-				                                         foldername,
+			                                                 KOLAB_MAIL_ACCESS_OPMODE_ONLINE,
+			                                                 KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_PUSH,
+			                                                 kmailhandle,
+			                                                 foldername,
 			                                                 record,
-				                                         &tmp_err);
+			                                                 &tmp_err);
 		else
 			ok = kolab_mail_synchronizer_transaction_abort (self,
-				                                        KOLAB_MAIL_ACCESS_OPMODE_ONLINE,
-				                                        KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_PUSH,
-				                                        kmailhandle,
-				                                        foldername,
+			                                                KOLAB_MAIL_ACCESS_OPMODE_ONLINE,
+			                                                KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_PUSH,
+			                                                kmailhandle,
+			                                                foldername,
 			                                                record,
-				                                        &tmp_err);
+			                                                &tmp_err);
 	uid_cleanup:
 		kolab_mail_info_db_record_free (record);
 		if (tmp_err != NULL) {
@@ -1655,7 +1655,7 @@ kolab_mail_synchronizer_configure  (KolabMailSynchronizer *self,
                                     GError **err)
 {
 	KolabMailSynchronizerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (ksettings));
 	g_assert (KOLAB_IS_MAIL_IMAP_CLIENT (client));
@@ -1675,7 +1675,7 @@ kolab_mail_synchronizer_configure  (KolabMailSynchronizer *self,
 	g_object_ref (infodb);
 	g_object_ref (sidecache);
 	g_object_ref (mimebuilder);
-	
+
 	priv->ksettings = ksettings;
 	priv->client = client;
 	priv->infodb = infodb;
@@ -1690,7 +1690,7 @@ kolab_mail_synchronizer_bringup (KolabMailSynchronizer *self,
                                  GError **err)
 {
 	KolabMailSynchronizerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1698,7 +1698,7 @@ kolab_mail_synchronizer_bringup (KolabMailSynchronizer *self,
 
 	if (priv->is_up == TRUE)
 		return TRUE;
-	
+
 	priv->is_up = TRUE;
 	return TRUE;
 }
@@ -1708,7 +1708,7 @@ kolab_mail_synchronizer_shutdown (KolabMailSynchronizer *self,
                                   GError **err)
 {
 	KolabMailSynchronizerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -1716,7 +1716,7 @@ kolab_mail_synchronizer_shutdown (KolabMailSynchronizer *self,
 
 	if (priv->is_up == FALSE)
 		return TRUE;
-	
+
 	/* TODO implement me */
 
 	priv->is_up = FALSE;
@@ -1737,7 +1737,7 @@ kolab_mail_synchronizer_handle_new_from_infodb (KolabMailSynchronizer *self,
 	KolabMailSummary *summary = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert (uid != NULL);
 	g_assert (foldername != NULL);
@@ -1769,8 +1769,8 @@ kolab_mail_synchronizer_handle_new_from_infodb (KolabMailSynchronizer *self,
 		g_propagate_error (err, tmp_err);
 		return NULL;
 	}
-	
-	return local_handle;	
+
+	return local_handle;
 }
 
 /*----------------------------------------------------------------------------*/
@@ -1814,7 +1814,7 @@ kolab_mail_synchronizer_transaction_prepare (KolabMailSynchronizer *self,
 	gboolean can_act = FALSE;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert ((opmode > KOLAB_MAIL_ACCESS_OPMODE_CONFIGURED) &&
 	          (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE));
@@ -1840,16 +1840,16 @@ kolab_mail_synchronizer_transaction_prepare (KolabMailSynchronizer *self,
 		goto cleanup;
 	}
 	kmh_summary = kolab_mail_handle_get_summary (kmailhandle);
-	
+
 	/* read InfoDb record for the UID in question
 	 * (if we don't have it already)
 	 */
 	if (*record == NULL) {
 		record_locally_created = TRUE;
 		*record = kolab_mail_info_db_query_record (priv->infodb,
-			                                   uid,
-			                                   foldername,
-			                                   &tmp_err);
+		                                           uid,
+		                                           foldername,
+		                                           &tmp_err);
 		if (tmp_err != NULL)
 			goto cleanup;
 	}
@@ -1908,7 +1908,7 @@ kolab_mail_synchronizer_transaction_prepare (KolabMailSynchronizer *self,
 	}
 
 	/* if we're here, uid exists in named folder on server */
-	
+
 	folder_type = kolab_mail_summary_get_uint_field (kmh_summary,
 	                                                 KOLAB_MAIL_SUMMARY_UINT_FIELD_FOLDER_TYPE);
 	folder_summary = kolab_mail_info_db_query_folder_summary (priv->infodb,
@@ -1926,7 +1926,7 @@ kolab_mail_synchronizer_transaction_prepare (KolabMailSynchronizer *self,
 	                                            foldername,
 	                                            folder_type,
 	                                            folder_context,
-	                                            uidval_changed);	
+	                                            uidval_changed);
 
 	status = kolab_mail_summary_get_uint_field ((*record)->summary,
 	                                            KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
@@ -1936,7 +1936,7 @@ kolab_mail_synchronizer_transaction_prepare (KolabMailSynchronizer *self,
 		can_act = TRUE;
 		goto cleanup;
 	}
-	
+
 	if ((ttid == KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_DELETE) ||
 	    (status & KOLAB_OBJECT_CACHE_STATUS_DELETED)) {
 		/* We pretend we can always delete. In case of a server side
@@ -1948,189 +1948,189 @@ kolab_mail_synchronizer_transaction_prepare (KolabMailSynchronizer *self,
 	}
 
 	/* if we're here, we're in PUSH/STORE operation */
-	
+
 	switch (sync_id) {
-		case KOLAB_SYNC_STRATEGY_CLIENT:
-			/* "always client" will simply overwrite */
-			g_debug ("%s: UID (%s) Folder (%s) will be overwritten, if exists",
-				 __func__, uid, foldername);
-			can_act = TRUE;
-			break;
-		case KOLAB_SYNC_STRATEGY_SERVER:
-			/* "take server" will never overwrite if server changed */
-			g_debug ("%s: UID (%s) Folder (%s) changed on server, won't overwrite",
-				 __func__, uid, foldername);
-			can_act = FALSE;
-			break;
-		case KOLAB_SYNC_STRATEGY_DUPE:
-			/* creates a duplicate uid for a server-changed object */
-			changed_uids_lst = kolab_mail_info_db_query_changed_uids (priv->infodb,
-				                                                  foldername,
-				                                                  NULL, /* sexp */
-				                                                  FALSE,
-				                                                  &tmp_err);
-			if (tmp_err != NULL)
-				goto cleanup;
-			changed_uids_tbl = kolab_util_glib_ghashtable_new_from_str_glist (changed_uids_lst);
-			kolab_util_glib_glist_free (changed_uids_lst);
-			changed_uids_lst = NULL;
-			new_uid = kolab_mail_synchronizer_new_free_uid (self,
-				                                        imap_summaries,
-				                                        changed_uids_tbl);
-			/* set new Kolab UID on handle */
-			ok = kolab_mail_handle_set_uid_full (kmailhandle, new_uid, &tmp_err);
-			if (! ok)
-				goto cleanup;
-			kmh_summary_nonconst = kolab_mail_handle_get_summary_nonconst (kmailhandle);
-			kolab_mail_summary_set_bool_field (kmh_summary_nonconst,
-			                                   KOLAB_MAIL_SUMMARY_BOOL_FIELD_COMPLETE,
-			                                   TRUE);
-			ok = kolab_mail_handle_convert_eds_to_kconvmail (kmailhandle,
-			                                                 &tmp_err);
-			if (! ok)
-				g_error ("%s: %s", __func__, tmp_err->message);
-			/* remaining handle updates */
-			kolab_mail_summary_set_char_field (kmh_summary_nonconst,
-			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_IMAP_UID,
-			                                   NULL);
-			/* update our new InfoDb record to the new UIDs */
-			kolab_mail_summary_set_char_field ((*record)->summary,
-			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_KOLAB_UID,
-			                                   g_strdup (new_uid));
-			kolab_mail_summary_set_char_field ((*record)->summary,
-			                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_IMAP_UID,
-			                                   NULL);
-			new_status = kolab_mail_summary_get_uint_field ((*record)->summary,
+	case KOLAB_SYNC_STRATEGY_CLIENT:
+		/* "always client" will simply overwrite */
+		g_debug ("%s: UID (%s) Folder (%s) will be overwritten, if exists",
+		         __func__, uid, foldername);
+		can_act = TRUE;
+		break;
+	case KOLAB_SYNC_STRATEGY_SERVER:
+		/* "take server" will never overwrite if server changed */
+		g_debug ("%s: UID (%s) Folder (%s) changed on server, won't overwrite",
+		         __func__, uid, foldername);
+		can_act = FALSE;
+		break;
+	case KOLAB_SYNC_STRATEGY_DUPE:
+		/* creates a duplicate uid for a server-changed object */
+		changed_uids_lst = kolab_mail_info_db_query_changed_uids (priv->infodb,
+		                                                          foldername,
+		                                                          NULL, /* sexp */
+		                                                          FALSE,
+		                                                          &tmp_err);
+		if (tmp_err != NULL)
+			goto cleanup;
+		changed_uids_tbl = kolab_util_glib_ghashtable_new_from_str_glist (changed_uids_lst);
+		kolab_util_glib_glist_free (changed_uids_lst);
+		changed_uids_lst = NULL;
+		new_uid = kolab_mail_synchronizer_new_free_uid (self,
+		                                                imap_summaries,
+		                                                changed_uids_tbl);
+		/* set new Kolab UID on handle */
+		ok = kolab_mail_handle_set_uid_full (kmailhandle, new_uid, &tmp_err);
+		if (! ok)
+			goto cleanup;
+		kmh_summary_nonconst = kolab_mail_handle_get_summary_nonconst (kmailhandle);
+		kolab_mail_summary_set_bool_field (kmh_summary_nonconst,
+		                                   KOLAB_MAIL_SUMMARY_BOOL_FIELD_COMPLETE,
+		                                   TRUE);
+		ok = kolab_mail_handle_convert_eds_to_kconvmail (kmailhandle,
+		                                                 &tmp_err);
+		if (! ok)
+			g_error ("%s: %s", __func__, tmp_err->message);
+		/* remaining handle updates */
+		kolab_mail_summary_set_char_field (kmh_summary_nonconst,
+		                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_IMAP_UID,
+		                                   NULL);
+		/* update our new InfoDb record to the new UIDs */
+		kolab_mail_summary_set_char_field ((*record)->summary,
+		                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_KOLAB_UID,
+		                                   g_strdup (new_uid));
+		kolab_mail_summary_set_char_field ((*record)->summary,
+		                                   KOLAB_MAIL_SUMMARY_CHAR_FIELD_IMAP_UID,
+		                                   NULL);
+		new_status = kolab_mail_summary_get_uint_field ((*record)->summary,
+		                                                KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
+		new_status |= KOLAB_OBJECT_CACHE_STATUS_CHANGED;
+		kolab_mail_summary_set_uint_field ((*record)->summary,
+		                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS,
+		                                   new_status);
+		kolab_mail_info_db_record_set_char_field (*record,
+		                                          KOLAB_MAIL_INFO_DB_RECORD_CHAR_FIELD_IMAP_UID_SYNC,
+		                                          NULL);
+		/* mark the old Kolab UID as changed so it will be reloaded */
+		old_record = kolab_mail_info_db_query_record (priv->infodb,
+		                                              uid, /* original Kolab UID */
+		                                              foldername,
+		                                              &tmp_err);
+		if (tmp_err != NULL) {
+			g_warning ("%s: %s", __func__, tmp_err->message);
+			g_free (tmp_err);
+			tmp_err = NULL;
+		}
+		if (old_record != NULL) {
+			KolabObjectCacheStatus old_status = KOLAB_OBJECT_CACHE_STATUS_INVAL;
+			KolabObjectCacheLocation old_location = KOLAB_OBJECT_CACHE_LOCATION_INVAL;
+			old_status = kolab_mail_summary_get_uint_field (old_record->summary,
 			                                                KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
-			new_status |= KOLAB_OBJECT_CACHE_STATUS_CHANGED;
-			kolab_mail_summary_set_uint_field ((*record)->summary,
+			old_status |= KOLAB_OBJECT_CACHE_STATUS_CHANGED;
+			kolab_mail_summary_set_uint_field (old_record->summary,
 			                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS,
-			                                   new_status);
-			kolab_mail_info_db_record_set_char_field (*record,
-			                                          KOLAB_MAIL_INFO_DB_RECORD_CHAR_FIELD_IMAP_UID_SYNC,
-			                                          NULL);
-			/* mark the old Kolab UID as changed so it will be reloaded */
-			old_record = kolab_mail_info_db_query_record (priv->infodb,
-			                                              uid, /* original Kolab UID */
-			                                              foldername,
-			                                              &tmp_err);
-			if (tmp_err != NULL) {
+			                                   old_status);
+			old_location = kolab_mail_summary_get_uint_field (old_record->summary,
+			                                                  KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION);
+			old_location &= ~((guint)KOLAB_OBJECT_CACHE_LOCATION_SIDE);
+			kolab_mail_summary_set_uint_field (old_record->summary,
+			                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
+			                                   old_location);
+			ok = kolab_mail_info_db_update_record (priv->infodb,
+			                                       old_record,
+			                                       foldername,
+			                                       &tmp_err);
+			if (! ok) {
 				g_warning ("%s: %s", __func__, tmp_err->message);
 				g_free (tmp_err);
 				tmp_err = NULL;
 			}
-			if (old_record != NULL) {
-				KolabObjectCacheStatus old_status = KOLAB_OBJECT_CACHE_STATUS_INVAL;
-				KolabObjectCacheLocation old_location = KOLAB_OBJECT_CACHE_LOCATION_INVAL;
-				old_status = kolab_mail_summary_get_uint_field (old_record->summary,
-				                                                KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
-				old_status |= KOLAB_OBJECT_CACHE_STATUS_CHANGED;
-				kolab_mail_summary_set_uint_field (old_record->summary,
-				                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS,
-				                                   old_status);
-				old_location = kolab_mail_summary_get_uint_field (old_record->summary,
-				                                                  KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION);
-				old_location &= ~((guint)KOLAB_OBJECT_CACHE_LOCATION_SIDE);
-				kolab_mail_summary_set_uint_field (old_record->summary,
-				                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
-				                                   old_location);
-				ok = kolab_mail_info_db_update_record (priv->infodb,
-				                                       old_record,
-				                                       foldername,
-				                                       &tmp_err);
-				if (! ok) {
-					g_warning ("%s: %s", __func__, tmp_err->message);
-					g_free (tmp_err);
-					tmp_err = NULL;
-				}
-				ok = kolab_mail_side_cache_delete_by_uid (priv->sidecache,
-				                                          uid,
-				                                          foldername,
-				                                          &tmp_err);
-				if (! ok) {
-					g_warning ("%s: %s", __func__, tmp_err->message);
-					g_free (tmp_err);
-					tmp_err = NULL;
-				}
-				kolab_mail_info_db_record_free (old_record);
-			}
-			g_debug ("%s: UID (%s) Folder (%s) creating dupe, new UID (%s)",
-				 __func__, uid, foldername, new_uid);
-			can_act = TRUE;
-			break;
-		case KOLAB_SYNC_STRATEGY_NEWEST:
-			/* keep the "newer" object. this works on timestamps,
-			 * which is sort of evil and may yield unexpected results
-			 * if client and server clocks are out of sync. YMMV.
-			 */
-			kmh_srv = kolab_mail_handle_new_from_handle (kmailhandle);
-			kolab_mail_handle_set_foldername (kmh_srv, foldername);
-
-			ok = kolab_mail_imap_client_retrieve (priv->client,
-					                      kmh_srv,
-			                                      FALSE, /* folder needs to be uptodate already */
-					                      &tmp_err);
+			ok = kolab_mail_side_cache_delete_by_uid (priv->sidecache,
+			                                          uid,
+			                                          foldername,
+			                                          &tmp_err);
 			if (! ok) {
-				if (tmp_err->code == KOLAB_BACKEND_ERROR_NOTFOUND) {
-					/* uid has _just_now_ been deleted on server,
-					 * we can write our object
-					 */
-					g_error_free (tmp_err);
-					tmp_err = NULL;
-					can_act = TRUE;
-				}
-				goto cleanup;
-			}
-			if (! kolab_mail_handle_has_kconvmail (kmailhandle)) {
-				/* oops, should not happen... try again */
-				ok = kolab_mail_side_cache_retrieve (priv->sidecache,
-				                                     kmailhandle,
-				                                     &tmp_err);
-				if (! ok)
-					/* object not found in SideCache */
-					goto cleanup;
+				g_warning ("%s: %s", __func__, tmp_err->message);
+				g_free (tmp_err);
+				tmp_err = NULL;
 			}
-			kmh_loc = kolab_mail_handle_new_from_handle_with_kconvmail (kmailhandle);
-			kolab_mail_handle_set_foldername (kmh_loc, foldername);
+			kolab_mail_info_db_record_free (old_record);
+		}
+		g_debug ("%s: UID (%s) Folder (%s) creating dupe, new UID (%s)",
+		         __func__, uid, foldername, new_uid);
+		can_act = TRUE;
+		break;
+	case KOLAB_SYNC_STRATEGY_NEWEST:
+		/* keep the "newer" object. this works on timestamps,
+		 * which is sort of evil and may yield unexpected results
+		 * if client and server clocks are out of sync. YMMV.
+		 */
+		kmh_srv = kolab_mail_handle_new_from_handle (kmailhandle);
+		kolab_mail_handle_set_foldername (kmh_srv, foldername);
 
-			/* convert to Evo datatype */
-			ok = kolab_mail_handle_convert_kconvmail_to_eds (kmh_srv,
-			                                                 &tmp_err);
-			if (! ok)
-				goto cleanup;
-			ok = kolab_mail_handle_convert_kconvmail_to_eds (kmh_loc,
-			                                                 &tmp_err);
+		ok = kolab_mail_imap_client_retrieve (priv->client,
+		                                      kmh_srv,
+		                                      FALSE, /* folder needs to be uptodate already */
+		                                      &tmp_err);
+		if (! ok) {
+			if (tmp_err->code == KOLAB_BACKEND_ERROR_NOTFOUND) {
+				/* uid has _just_now_ been deleted on server,
+				 * we can write our object
+				 */
+				g_error_free (tmp_err);
+				tmp_err = NULL;
+				can_act = TRUE;
+			}
+			goto cleanup;
+		}
+		if (! kolab_mail_handle_has_kconvmail (kmailhandle)) {
+			/* oops, should not happen... try again */
+			ok = kolab_mail_side_cache_retrieve (priv->sidecache,
+			                                     kmailhandle,
+			                                     &tmp_err);
 			if (! ok)
+				/* object not found in SideCache */
 				goto cleanup;
-			
-			/* datetime comparison between kmailhandle and kmh_server */
-			switch (folder_context) {
-				case KOLAB_FOLDER_CONTEXT_CONTACT:
-					econtact_loc = kolab_mail_handle_get_econtact (kmh_loc);
-					econtact_srv = kolab_mail_handle_get_econtact (kmh_srv);
-					can_act = kolab_mail_synchronizer_act_on_econtact (econtact_loc,
-					                                                   econtact_srv,
-					                                                   uid,
-					                                                   foldername);
-					break;
-				case KOLAB_FOLDER_CONTEXT_CALENDAR:
-					ecalcomp_loc = kolab_mail_handle_get_ecalcomponent (kmh_loc);
-					ecalcomp_srv = kolab_mail_handle_get_ecalcomponent (kmh_srv);
-					can_act = kolab_mail_synchronizer_act_on_ecalcomp (ecalcomp_loc,
-					                                                   ecalcomp_srv,
-					                                                   uid,
-					                                                   foldername);
-					break;
-				default:
-					g_assert_not_reached ();
-			}
-			
+		}
+		kmh_loc = kolab_mail_handle_new_from_handle_with_kconvmail (kmailhandle);
+		kolab_mail_handle_set_foldername (kmh_loc, foldername);
+
+		/* convert to Evo datatype */
+		ok = kolab_mail_handle_convert_kconvmail_to_eds (kmh_srv,
+		                                                 &tmp_err);
+		if (! ok)
+			goto cleanup;
+		ok = kolab_mail_handle_convert_kconvmail_to_eds (kmh_loc,
+		                                                 &tmp_err);
+		if (! ok)
+			goto cleanup;
+
+		/* datetime comparison between kmailhandle and kmh_server */
+		switch (folder_context) {
+		case KOLAB_FOLDER_CONTEXT_CONTACT:
+			econtact_loc = kolab_mail_handle_get_econtact (kmh_loc);
+			econtact_srv = kolab_mail_handle_get_econtact (kmh_srv);
+			can_act = kolab_mail_synchronizer_act_on_econtact (econtact_loc,
+			                                                   econtact_srv,
+			                                                   uid,
+			                                                   foldername);
+			break;
+		case KOLAB_FOLDER_CONTEXT_CALENDAR:
+			ecalcomp_loc = kolab_mail_handle_get_ecalcomponent (kmh_loc);
+			ecalcomp_srv = kolab_mail_handle_get_ecalcomponent (kmh_srv);
+			can_act = kolab_mail_synchronizer_act_on_ecalcomp (ecalcomp_loc,
+			                                                   ecalcomp_srv,
+			                                                   uid,
+			                                                   foldername);
 			break;
 		default:
 			g_assert_not_reached ();
+		}
+
+		break;
+	default:
+		g_assert_not_reached ();
 	}
 
-cleanup:
+ cleanup:
 	if (tmp_err != NULL) {
 		if (record_locally_created) {
 			kolab_mail_info_db_record_free (*record);
@@ -2177,7 +2177,7 @@ kolab_mail_synchronizer_transaction_start (KolabMailSynchronizer *self,
                                            GError **err)
 {
 	KolabMailSynchronizerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert ((opmode > KOLAB_MAIL_ACCESS_OPMODE_CONFIGURED) &&
 	          (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE));
@@ -2192,7 +2192,7 @@ kolab_mail_synchronizer_transaction_start (KolabMailSynchronizer *self,
 	priv = KOLAB_MAIL_SYNCHRONIZER_PRIVATE (self);
 
 	g_assert (priv->is_up == TRUE);
-	
+
 	/* TODO implement me */
 
 	/* checks needed:
@@ -2238,7 +2238,7 @@ kolab_mail_synchronizer_transaction_abort (KolabMailSynchronizer *self,
                                            GError **err)
 {
 	KolabMailSynchronizerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert ((opmode > KOLAB_MAIL_ACCESS_OPMODE_CONFIGURED) &&
 	          (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE));
@@ -2253,7 +2253,7 @@ kolab_mail_synchronizer_transaction_abort (KolabMailSynchronizer *self,
 	priv = KOLAB_MAIL_SYNCHRONIZER_PRIVATE (self);
 
 	g_assert (priv->is_up == TRUE);
-	
+
 	/* TODO implement me */
 
 	return TRUE;
@@ -2277,7 +2277,7 @@ kolab_mail_synchronizer_transaction_commit (KolabMailSynchronizer *self,
 	KolabFolderContextID folder_context = KOLAB_FOLDER_CONTEXT_INVAL;
 	gboolean ok = TRUE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert ((opmode > KOLAB_MAIL_ACCESS_OPMODE_CONFIGURED) &&
 	          (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE));
@@ -2298,7 +2298,7 @@ kolab_mail_synchronizer_transaction_commit (KolabMailSynchronizer *self,
 		g_warning ("%s: folder operations not yet implemented", __func__);
 		g_assert_not_reached ();
 	}
-	
+
 	uid = kolab_mail_handle_get_uid (kmailhandle);
 
 	/* updates for store or push operations in online operation */
@@ -2321,7 +2321,7 @@ kolab_mail_synchronizer_transaction_commit (KolabMailSynchronizer *self,
 		}
 
 		kolab_mail_handle_unset_cache_location (kmailhandle,
-			                                KOLAB_OBJECT_CACHE_LOCATION_SIDE);
+		                                        KOLAB_OBJECT_CACHE_LOCATION_SIDE);
 		kolab_mail_handle_set_cache_location (kmailhandle,
 		                                      KOLAB_OBJECT_CACHE_LOCATION_IMAP);
 		location = kolab_mail_summary_get_uint_field (record->summary,
@@ -2331,21 +2331,21 @@ kolab_mail_synchronizer_transaction_commit (KolabMailSynchronizer *self,
 		kolab_mail_summary_set_uint_field (record->summary,
 		                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
 		                                   location);
-		update_skip:
-		    { /* nop */ }
+	update_skip:
+		{ /* nop */ }
 	}
 
 	/* updates for store operation in offline mode */
 	if ((ttid == KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_STORE) &&
 	    (opmode == KOLAB_MAIL_ACCESS_OPMODE_OFFLINE)) {
-			kolab_mail_handle_set_cache_location (kmailhandle,
-			                                      KOLAB_OBJECT_CACHE_LOCATION_SIDE);
-			location = kolab_mail_summary_get_uint_field (record->summary,
-			                                              KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION);
-			location |= (guint)KOLAB_OBJECT_CACHE_LOCATION_SIDE;
-			kolab_mail_summary_set_uint_field (record->summary,
-			                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
-			                                   location);
+		kolab_mail_handle_set_cache_location (kmailhandle,
+		                                      KOLAB_OBJECT_CACHE_LOCATION_SIDE);
+		location = kolab_mail_summary_get_uint_field (record->summary,
+		                                              KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION);
+		location |= (guint)KOLAB_OBJECT_CACHE_LOCATION_SIDE;
+		kolab_mail_summary_set_uint_field (record->summary,
+		                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
+		                                   location);
 	}
 
 	/* updates for delete operation in online-mode not needed */
@@ -2353,19 +2353,19 @@ kolab_mail_synchronizer_transaction_commit (KolabMailSynchronizer *self,
 	/* updates for delete operation in offline mode */
 	if ((ttid == KOLAB_MAIL_SYNCHRONIZER_TRANSACTION_TYPE_DELETE) &&
 	    (opmode == KOLAB_MAIL_ACCESS_OPMODE_OFFLINE)) {
-		    status = kolab_mail_summary_get_uint_field (record->summary,
-		                                                KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
-		    status |= (guint)KOLAB_OBJECT_CACHE_STATUS_DELETED;
-		    kolab_mail_summary_set_uint_field (record->summary,
-		                                       KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS,
-		                                       status);
-		    location = kolab_mail_summary_get_uint_field (record->summary,
-		                                                  KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION);
-		    location &= ~((guint)KOLAB_OBJECT_CACHE_LOCATION_SIDE);
-		    kolab_mail_summary_set_uint_field (record->summary,
-		                                       KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
-		                                       location);
-		    /* no need to care for the handle here, it will be destroyed */
+		status = kolab_mail_summary_get_uint_field (record->summary,
+		                                            KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS);
+		status |= (guint)KOLAB_OBJECT_CACHE_STATUS_DELETED;
+		kolab_mail_summary_set_uint_field (record->summary,
+		                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_STATUS,
+		                                   status);
+		location = kolab_mail_summary_get_uint_field (record->summary,
+		                                              KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION);
+		location &= ~((guint)KOLAB_OBJECT_CACHE_LOCATION_SIDE);
+		kolab_mail_summary_set_uint_field (record->summary,
+		                                   KOLAB_MAIL_SUMMARY_UINT_FIELD_CACHE_LOCATION,
+		                                   location);
+		/* no need to care for the handle here, it will be destroyed */
 	}
 
 	summary = kolab_mail_handle_get_summary (kmailhandle);
@@ -2401,9 +2401,9 @@ kolab_mail_synchronizer_transaction_commit (KolabMailSynchronizer *self,
 		                                       &tmp_err);
 	} else {
 		ok = kolab_mail_info_db_update_record (priv->infodb,
-			                               record,
-			                               foldername,
-			                               &tmp_err);
+		                                       record,
+		                                       foldername,
+		                                       &tmp_err);
 	}
 
 	if (! ok) {
@@ -2432,7 +2432,7 @@ kolab_mail_synchronizer_info_sync (KolabMailSynchronizer *self,
 	gboolean ok = TRUE;
 	GError *tmp_err = NULL;
 	GError *tmp_err_2 = NULL;
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert ((opmode > KOLAB_MAIL_ACCESS_OPMODE_CONFIGURED) &&
 	          (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE));
@@ -2448,7 +2448,7 @@ kolab_mail_synchronizer_info_sync (KolabMailSynchronizer *self,
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
 		return FALSE;
-	}	
+	}
 	ok = kolab_mail_synchronizer_folders_update_infodb (self,
 	                                                    opmode,
 	                                                    &tmp_err);
@@ -2491,17 +2491,17 @@ kolab_mail_synchronizer_info_sync (KolabMailSynchronizer *self,
 	if (! ok) {
 		g_propagate_error (err, tmp_err);
 		return FALSE;
-	}	
+	}
 	folders_lst_ptr = folders_lst;
 	while (folders_lst_ptr != NULL) {
 		gchar *fn = (gchar *)(folders_lst_ptr->data);
 		ok = kolab_mail_synchronizer_uids_update_infodb (self,
-			                                         opmode,
-			                                         fn,
-			                                         &tmp_err);
+		                                                 opmode,
+		                                                 fn,
+		                                                 &tmp_err);
 		if (! ok)
 			break;
-		
+
 		folders_lst_ptr = g_list_next (folders_lst_ptr);
 	}
 	kolab_util_glib_glist_free (folders_lst);
@@ -2544,7 +2544,7 @@ kolab_mail_synchronizer_full_sync (KolabMailSynchronizer *self,
 	/* kolab_mail_synchronizer_info_sync() must have run
 	 * successfully prior to calling this function
 	 */
-	
+
 	g_assert (KOLAB_IS_MAIL_SYNCHRONIZER (self));
 	g_assert ((opmode > KOLAB_MAIL_ACCESS_OPMODE_CONFIGURED) &&
 	          (opmode < KOLAB_MAIL_ACCESS_LAST_OPMODE));
diff --git a/src/libekolab/kolab-settings-handler.c b/src/libekolab/kolab-settings-handler.c
index ae82470..95a3aba 100644
--- a/src/libekolab/kolab-settings-handler.c
+++ b/src/libekolab/kolab-settings-handler.c
@@ -12,17 +12,17 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
  */
- 
+
 /*----------------------------------------------------------------------------*/
 
 #include <errno.h>
@@ -111,31 +111,31 @@ kolab_settings_handler_char_get_func_camel_data_dir (KolabSettingsHandler *self,
 	gchar *data_dir = NULL;
 	gchar *priv_data_dir = NULL;
 	gchar *backend_dir = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
 	priv = KOLAB_SETTINGS_HANDLER_PRIVATE (self);
 	context = priv->sdata_uint[KOLAB_SETTINGS_HANDLER_UINT_FIELD_FOLDER_CONTEXT];
-	
+
 	priv_data_dir = priv->sdata_char[KOLAB_SETTINGS_HANDLER_CHAR_FIELD_CAMEL_DATA_DIR];
 	if (priv_data_dir != NULL)
 		return TRUE;
 
 	/* TODO elaborate on directory creation */
-	
+
 	switch (context) {
-		case KOLAB_FOLDER_CONTEXT_EMAIL:
-			backend_dir = g_strdup ("mail");
-			break;
-		case KOLAB_FOLDER_CONTEXT_CONTACT:
-			backend_dir = g_strdup ("addressbook");
-			break;
-		case KOLAB_FOLDER_CONTEXT_CALENDAR:
-			backend_dir = g_strdup ("calendar");
-			break;
-		default:
-			g_assert_not_reached ();
+	case KOLAB_FOLDER_CONTEXT_EMAIL:
+		backend_dir = g_strdup ("mail");
+		break;
+	case KOLAB_FOLDER_CONTEXT_CONTACT:
+		backend_dir = g_strdup ("addressbook");
+		break;
+	case KOLAB_FOLDER_CONTEXT_CALENDAR:
+		backend_dir = g_strdup ("calendar");
+		break;
+	default:
+		g_assert_not_reached ();
 	}
 	data_dir = g_build_filename (e_get_user_data_dir (),
 	                             backend_dir,
@@ -147,7 +147,7 @@ kolab_settings_handler_char_get_func_camel_data_dir (KolabSettingsHandler *self,
 		             G_FILE_ERROR,
 		             g_file_error_from_errno (errno),
 		             "%s: could not create directory %s: %s",
-		             __func__, data_dir, g_strerror (errno));		
+		             __func__, data_dir, g_strerror (errno));
 		g_free (data_dir);
 		return FALSE;
 	}
@@ -192,13 +192,13 @@ kolab_settings_handler_char_get_func_camel_config_dir (KolabSettingsHandler *sel
 	data_dir = priv->sdata_char[KOLAB_SETTINGS_HANDLER_CHAR_FIELD_CAMEL_DATA_DIR];
 
 	config_dir = g_build_filename (data_dir, "config", NULL);
-	
+
 	if (g_mkdir_with_parents (config_dir, 0700) != 0) {
 		g_set_error (err,
 		             G_FILE_ERROR,
 		             g_file_error_from_errno (errno),
 		             "%s: could not create directory %s: %s",
-		             __func__, config_dir, g_strerror (errno));		
+		             __func__, config_dir, g_strerror (errno));
 		g_free (config_dir);
 		return FALSE;
 	}
@@ -246,7 +246,7 @@ kolab_settings_handler_init (KolabSettingsHandler *object)
 
 	self = KOLAB_SETTINGS_HANDLER (object);
 	priv = KOLAB_SETTINGS_HANDLER_PRIVATE (self);
-	
+
 	for (ii = 0; ii < KOLAB_SETTINGS_HANDLER_CHAR_LAST_FIELD; ii++)
 		priv->sdata_char[ii] = NULL;
 	for (ii = 0; ii < KOLAB_SETTINGS_HANDLER_UINT_LAST_FIELD; ii++)
@@ -266,7 +266,7 @@ kolab_settings_handler_init (KolabSettingsHandler *object)
 	priv->sdata_int[KOLAB_SETTINGS_HANDLER_INT_FIELD_KOLAB_SERVER_LDAPS_PORT] = -1;
 
 	priv->sdata_tbl = NULL;
-	
+
 	priv->is_configured = FALSE;
 	priv->is_up = FALSE;
 }
@@ -279,7 +279,7 @@ kolab_settings_handler_dispose (GObject *object)
 
 	self = KOLAB_SETTINGS_HANDLER (object);
 	priv = KOLAB_SETTINGS_HANDLER_PRIVATE (self);
-	
+
 	/* TODO: Add dispose code here */
 
 	G_OBJECT_CLASS (kolab_settings_handler_parent_class)->dispose (object);
@@ -294,7 +294,7 @@ kolab_settings_handler_finalize (GObject *object)
 
 	self = KOLAB_SETTINGS_HANDLER (object);
 	priv = KOLAB_SETTINGS_HANDLER_PRIVATE (self);
-	
+
 	for (ii = 0; ii < KOLAB_SETTINGS_HANDLER_CHAR_LAST_FIELD; ii++) {
 		if (priv->sdata_char[ii] != NULL)
 			g_free (priv->sdata_char[ii]);
@@ -341,7 +341,7 @@ kolab_settings_handler_configure  (KolabSettingsHandler *self,
                                    GError **err)
 {
 	KolabSettingsHandlerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	g_assert ((context > KOLAB_FOLDER_CONTEXT_INVAL) &&
 	          (context < KOLAB_FOLDER_LAST_CONTEXT));
@@ -354,7 +354,7 @@ kolab_settings_handler_configure  (KolabSettingsHandler *self,
 		return TRUE;
 
 	priv->sdata_uint[KOLAB_SETTINGS_HANDLER_UINT_FIELD_FOLDER_CONTEXT] = context;
-	
+
 	priv->is_configured = TRUE;
 	return TRUE;
 }
@@ -377,7 +377,7 @@ kolab_settings_handler_bringup (KolabSettingsHandler *self,
                                 GError **err)
 {
 	KolabSettingsHandlerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -385,7 +385,7 @@ kolab_settings_handler_bringup (KolabSettingsHandler *self,
 
 	g_assert (priv->is_configured == TRUE);
 	g_assert (priv->is_up == FALSE);
-	
+
 	/* TODO implement me */
 
 	priv->is_up = TRUE;
@@ -409,7 +409,7 @@ kolab_settings_handler_shutdown (KolabSettingsHandler *self,
                                  GError **err)
 {
 	KolabSettingsHandlerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
 
@@ -417,7 +417,7 @@ kolab_settings_handler_shutdown (KolabSettingsHandler *self,
 
 	g_assert (priv->is_configured == TRUE);
 	g_assert (priv->is_up == TRUE);
-	
+
 	/* TODO implement me */
 
 	priv->is_up = FALSE;
@@ -453,7 +453,7 @@ kolab_settings_handler_set_char_field (KolabSettingsHandler *self,
 	KolabSettingsHandlerCharSetFunc setfunc = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	g_assert (field_id < KOLAB_SETTINGS_HANDLER_CHAR_LAST_FIELD);
 	/* value may be NULL */
@@ -500,7 +500,7 @@ kolab_settings_handler_get_char_field (KolabSettingsHandler *self,
 	KolabSettingsHandlerGetFunc getfunc = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	g_assert (field_id < KOLAB_SETTINGS_HANDLER_CHAR_LAST_FIELD);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -546,7 +546,7 @@ kolab_settings_handler_set_uint_field (KolabSettingsHandler *self,
 	KolabSettingsHandlerUintSetFunc setfunc = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	g_assert (field_id < KOLAB_SETTINGS_HANDLER_UINT_LAST_FIELD);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -565,7 +565,7 @@ kolab_settings_handler_set_uint_field (KolabSettingsHandler *self,
 		}
 	}
 
-	priv->sdata_uint[field_id] = value;	
+	priv->sdata_uint[field_id] = value;
 	return TRUE;
 }
 
@@ -590,7 +590,7 @@ kolab_settings_handler_get_uint_field (KolabSettingsHandler *self,
 	KolabSettingsHandlerGetFunc getfunc = NULL;
 	gboolean ok = FALSE;
 	GError *tmp_err = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	g_assert (field_id < KOLAB_SETTINGS_HANDLER_UINT_LAST_FIELD);
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -633,7 +633,7 @@ kolab_settings_handler_set_int_field (KolabSettingsHandler *self,
                                       GError **err)
 {
 	KolabSettingsHandlerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	/* g_assert (field_id < KOLAB_SETTINGS_HANDLER_INT_LAST_FIELD); */
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -643,7 +643,7 @@ kolab_settings_handler_set_int_field (KolabSettingsHandler *self,
 	g_assert (priv->is_configured == TRUE);
 	g_assert (priv->is_up == TRUE);
 
-	priv->sdata_int[field_id] = value;	
+	priv->sdata_int[field_id] = value;
 	return TRUE;
 }
 
@@ -665,7 +665,7 @@ kolab_settings_handler_get_int_field (KolabSettingsHandler *self,
                                       GError **err)
 {
 	KolabSettingsHandlerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	/* g_assert (field_id < KOLAB_SETTINGS_HANDLER_INT_LAST_FIELD); */
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -699,7 +699,7 @@ kolab_settings_handler_set_bool_field (KolabSettingsHandler *self,
                                        GError **err)
 {
 	KolabSettingsHandlerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	/* g_assert (field_id < KOLAB_SETTINGS_HANDLER_BOOL_LAST_FIELD); */
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -709,7 +709,7 @@ kolab_settings_handler_set_bool_field (KolabSettingsHandler *self,
 	g_assert (priv->is_configured == TRUE);
 	g_assert (priv->is_up == TRUE);
 
-	priv->sdata_bool[field_id] = value;	
+	priv->sdata_bool[field_id] = value;
 	return TRUE;
 }
 
@@ -731,7 +731,7 @@ kolab_settings_handler_get_bool_field (KolabSettingsHandler *self,
                                        GError **err)
 {
 	KolabSettingsHandlerPrivate *priv = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	/* g_assert (field_id < KOLAB_SETTINGS_HANDLER_BOOL_LAST_FIELD); */
 	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
@@ -752,20 +752,20 @@ kolab_settings_handler_create_table (KolabSettingsHandlerTblID tbl_id)
 	/* g_assert (tbl_id < KOLAB_SETTINGS_HANDLER_TBL_LAST_ID); */
 
 	switch (tbl_id) {
-		case KOLAB_SETTINGS_HANDLER_TBL_SYNCSTRATEGY:
-			/* GINT_TO_POINTER() values (don't free()) */
-			return g_hash_table_new_full (g_str_hash,
-			                              g_str_equal,
-			                              g_free,
-			                              NULL);
-		case KOLAB_SETTINGS_HANDLER_TBL_FOLDERCREATE:
-			/* values are pointers to keys, don't free() */
-			return g_hash_table_new_full (g_str_hash,
-			                              g_str_equal,
-			                              g_free,
-			                              NULL);
-		default:
-			g_assert_not_reached ();
+	case KOLAB_SETTINGS_HANDLER_TBL_SYNCSTRATEGY:
+		/* GINT_TO_POINTER() values (don't free()) */
+		return g_hash_table_new_full (g_str_hash,
+		                              g_str_equal,
+		                              g_free,
+		                              NULL);
+	case KOLAB_SETTINGS_HANDLER_TBL_FOLDERCREATE:
+		/* values are pointers to keys, don't free() */
+		return g_hash_table_new_full (g_str_hash,
+		                              g_str_equal,
+		                              g_free,
+		                              NULL);
+	default:
+		g_assert_not_reached ();
 	}
 }
 
@@ -799,7 +799,7 @@ kolab_settings_handler_set_value (KolabSettingsHandler *self,
 {
 	KolabSettingsHandlerPrivate *priv = NULL;
 	GHashTable *tbl = NULL;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	/* g_assert (tbl_id < KOLAB_SETTINGS_HANDLER_TBL_LAST_ID); */
 	g_assert (key != NULL);
@@ -823,7 +823,7 @@ kolab_settings_handler_set_value (KolabSettingsHandler *self,
 		                     GINT_TO_POINTER (tbl_id),
 		                     tbl);
 	}
-		
+
 	g_hash_table_replace (tbl, g_strdup (key), value);
 	return TRUE;
 }
@@ -860,7 +860,7 @@ kolab_settings_handler_get_value (KolabSettingsHandler *self,
 	gpointer value = NULL;
 	gpointer orig_key = NULL;
 	gboolean found = FALSE;
-	
+
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (self));
 	/* g_assert (tbl_id < KOLAB_SETTINGS_HANDLER_TBL_LAST_ID); */
 	g_assert (key != NULL);
diff --git a/src/libekolab/kolab-util-backend.c b/src/libekolab/kolab-util-backend.c
index ea1cfb4..cdf56ac 100644
--- a/src/libekolab/kolab-util-backend.c
+++ b/src/libekolab/kolab-util-backend.c
@@ -12,17 +12,17 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
  */
- 
+
 /*----------------------------------------------------------------------------*/
 
 #include "kolab-types.h"
@@ -57,14 +57,14 @@ const gchar *kolab_tls_variant_desc[KOLAB_TLS_LAST_VARIANT] = {
 GQuark
 kolab_util_backend_error_quark (void)
 {
-        static GQuark quark = 0;
+	static GQuark quark = 0;
 
-        if (G_UNLIKELY (quark == 0)) {
-                const gchar *string = "kolab-backend-error-quark";
-                quark = g_quark_from_static_string (string);
-        }
+	if (G_UNLIKELY (quark == 0)) {
+		const gchar *string = "kolab-backend-error-quark";
+		quark = g_quark_from_static_string (string);
+	}
 
-        return quark;
+	return quark;
 }
 
 /*----------------------------------------------------------------------------*/
@@ -184,7 +184,7 @@ kolab_util_misc_req_pkcs11_from_property (const gchar *req_pkcs11_prop)
 }
 
 void
-kolab_util_backend_koma_table_cleanup_cb (gpointer data, 
+kolab_util_backend_koma_table_cleanup_cb (gpointer data,
                                           GObject *object,
                                           gboolean is_last_ref)
 {
@@ -195,17 +195,17 @@ kolab_util_backend_koma_table_cleanup_cb (gpointer data,
 	gchar *user_at_server = NULL;
 	KolabSettingsHandler *ksettings = NULL;
 	gboolean ok;
-g_debug ("%s()[%u] called.", __func__, __LINE__);
+	g_debug ("%s()[%u] called.", __func__, __LINE__);
 
 	g_assert (G_IS_OBJECT (object));
 	(void)is_last_ref;
-	
+
 	ksettings = kolab_mail_access_get_settings_handler (koma);
 	servername = kolab_settings_handler_get_char_field (ksettings, KOLAB_SETTINGS_HANDLER_CHAR_FIELD_KOLAB_SERVER_NAME, NULL);
 	username = kolab_settings_handler_get_char_field (ksettings, KOLAB_SETTINGS_HANDLER_CHAR_FIELD_KOLAB_USER_NAME, NULL);
 	user_at_server = g_strdup_printf ("%s %s", username, servername);
 	ok = g_hash_table_remove (koma_table, user_at_server);
-	
+
 	g_free (user_at_server);
 	g_object_remove_toggle_ref (object, kolab_util_backend_koma_table_cleanup_cb, data);
 } /* kolab_util_backend_koma_table_cleanup_cb () */
@@ -216,7 +216,7 @@ kolab_util_backend_modtime_set_on_econtact (EContact *econtact)
 	time_t rawtime;
 	struct tm *ts = NULL;
 	gchar *buf = NULL;
-	
+
 	g_assert (E_IS_CONTACT (econtact));
 
 	time (&rawtime);
@@ -231,7 +231,7 @@ void
 kolab_util_backend_modtime_set_on_ecalcomp (ECalComponent *ecalcomp)
 {
 	struct icaltimetype itt;
-	
+
 	g_assert (E_IS_CAL_COMPONENT (ecalcomp));
 
 	itt = icaltime_current_time_with_zone (NULL); /* need UTC here, hence NULL timezone */
@@ -247,16 +247,16 @@ kolab_util_backend_prepare_settings (KolabSettingsHandler *ksettings,
                                      const gchar *sourcename,
                                      const KolabSyncStrategyID *sync_value)
 {
-	/* Note: Currently (2.30), there is no good way of returning errors from 
+	/* Note: Currently (2.30), there is no good way of returning errors from
 	 * the backend to the frontends. So this helper function simply notifies
 	 * on stdout/stderr and proceeds.
 	 */
 	const gchar *prop_str = NULL;
 	KolabTLSVariantID enc_value;
 	KolabReqPkcs11 req_pkcs11_value;
-	
+
 	GError *error = NULL;
-g_debug ("%s()[%u] called.", __func__, __LINE__);
+	g_debug ("%s()[%u] called.", __func__, __LINE__);
 	if (esource != NULL) {
 		prop_str = e_source_get_uri (esource);
 		(void) kolab_settings_handler_set_char_field (ksettings, KOLAB_SETTINGS_HANDLER_CHAR_FIELD_KOLAB_URI, g_strdup (prop_str), &error);
@@ -335,8 +335,8 @@ kolab_util_backend_sqlite_db_new_open (KolabUtilSqliteDb **kdb,
 	g_assert ((kdb != NULL) && (*kdb == NULL));
 	g_assert (KOLAB_IS_SETTINGS_HANDLER (ksettings));
 	g_assert (dbfilename != NULL);
-	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);	
-	
+	g_return_val_if_fail (err == NULL || *err == NULL, FALSE);
+
 	dbpath = kolab_settings_handler_get_char_field (ksettings,
 	                                                KOLAB_SETTINGS_HANDLER_CHAR_FIELD_CAMEL_ACCOUNT_DIR,
 	                                                &tmp_err);
@@ -361,6 +361,6 @@ kolab_util_backend_sqlite_db_new_open (KolabUtilSqliteDb **kdb,
 		g_propagate_error (err, tmp_err);
 		return FALSE;
 	}
-	
+
 	return TRUE;
 }
diff --git a/src/libekolab/kolab-util-backend.h b/src/libekolab/kolab-util-backend.h
index f6fe37d..ab1278b 100644
--- a/src/libekolab/kolab-util-backend.h
+++ b/src/libekolab/kolab-util-backend.h
@@ -12,17 +12,17 @@
  * modify it under the terms of the GNU Lesser General Public
  * License as published by the Free Software Foundation; either
  * version 2.1 of the License, or (at your option) any later version.
- * 
+ *
  * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
- * 
+ *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this program; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor Boston, MA 02110-1301,  USA
  */
- 
+
 /*----------------------------------------------------------------------------*/
 
 #ifndef _KOLAB_UTIL_BACKEND_H_
@@ -48,7 +48,7 @@
 #define KOLAB_BACKEND_ERROR (kolab_util_backend_error_quark ())
 
 typedef enum {
-        KOLAB_BACKEND_ERROR_GENERIC = 0,	/* lazy fallback error */
+	KOLAB_BACKEND_ERROR_GENERIC = 0,	/* lazy fallback error */
 	KOLAB_BACKEND_ERROR_INTERNAL,		/* internal (programming) error */
 	KOLAB_BACKEND_ERROR_NOTFOUND,		/* any object was not found */
 	KOLAB_BACKEND_ERROR_SYNC_NOTSTORED,     /* object not stored due to sync conflict */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]