From 10417c241d3aefd43c5797c82386b2dd046774ce Mon Sep 17 00:00:00 2001 From: Ludovic Marcotte Date: Sun, 22 Mar 2009 14:20:50 +0000 Subject: [PATCH 1/2] we initialize the ready state Monotone-Parent: f7a4e6329dc23e00a3a0de99cd95bb15d432656d Monotone-Revision: 1674514cbbb8b36021bc36e83a4fa580fe5718cf Monotone-Author: ludovic@Sophos.ca Monotone-Date: 2009-03-22T14:20:50 Monotone-Branch: ca.inverse.sogo --- SoObjects/SOGo/SOGoUserDefaults.m | 1 + 1 file changed, 1 insertion(+) diff --git a/SoObjects/SOGo/SOGoUserDefaults.m b/SoObjects/SOGo/SOGoUserDefaults.m index 01a726a7c..62cf0cf3e 100644 --- a/SoObjects/SOGo/SOGoUserDefaults.m +++ b/SoObjects/SOGo/SOGoUserDefaults.m @@ -56,6 +56,7 @@ static NSString *uidColumnName = @"c_uid"; fieldName = [theFieldName copy]; url = [theURL copy]; uid = [theUID copy]; + defFlags.ready = YES; } else { From da51be06192a0fe83b8c00ecc87dfca308b35308 Mon Sep 17 00:00:00 2001 From: Ludovic Marcotte Date: Sun, 22 Mar 2009 14:40:50 +0000 Subject: [PATCH 2/2] Small optimization Monotone-Parent: 1674514cbbb8b36021bc36e83a4fa580fe5718cf Monotone-Revision: ed796ed4ba5a6027433e3f18b4431d54833aeef8 Monotone-Author: ludovic@Sophos.ca Monotone-Date: 2009-03-22T14:40:50 Monotone-Branch: ca.inverse.sogo --- SoObjects/SOGo/SOGoUserDefaults.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/SoObjects/SOGo/SOGoUserDefaults.m b/SoObjects/SOGo/SOGoUserDefaults.m index 62cf0cf3e..5008636d0 100644 --- a/SoObjects/SOGo/SOGoUserDefaults.m +++ b/SoObjects/SOGo/SOGoUserDefaults.m @@ -356,7 +356,7 @@ static NSString *uidColumnName = @"c_uid"; { id old; - if (![self fetchProfile]) + if (!defFlags.ready || ![self fetchProfile]) return; /* check whether the value is actually modified */