Monotone-Parent: 3f8608c82d9c379cc9e0fea6ffe853cc1949a24b

Monotone-Revision: 905276f295d6f28a6946297f6a7af9ad60f71842

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2012-06-29T17:59:38
Monotone-Branch: ca.inverse.sogo
This commit is contained in:
Wolfgang Sourdeau
2012-06-29 17:59:38 +00:00
parent 591306481b
commit 95a443d89a
67 changed files with 2606 additions and 1873 deletions

View File

@@ -26,7 +26,7 @@
#import "MAPIStoreUserContext.h"
#import "NSString+MAPIStore.h"
#import "SOGoMAPIFSFolder.h"
#import "SOGoMAPIDBFolder.h"
#import "MAPIStoreFallbackContext.h"
@@ -51,10 +51,11 @@
inMemCtx: (TALLOC_CTX *) memCtx
{
struct mapistore_contexts_list *firstContext = NULL, *context;
SOGoMAPIFSFolder *root;
SOGoMAPIDBFolder *root;
NSArray *names;
NSUInteger count, max;
NSString *baseURL, *url, *name;
MAPIStoreUserContext *userContext;
baseURL = [NSString stringWithFormat: @"sogo://%@@fallback/", userName];
@@ -67,11 +68,15 @@
DLIST_ADD_END (firstContext, context, void);
/* Maybe emsmdbp_provisioning should be fixed in order to only take the uri
returned above to avoid deleting its entries... */
root = [SOGoMAPIFSFolder folderWithURL: [NSURL URLWithString: baseURL]
andTableType: MAPISTORE_MESSAGE_TABLE];
root = [SOGoMAPIDBFolder objectWithName: [self MAPIModuleName]
inContainer: nil];
[root setOwner: userName];
userContext = [MAPIStoreUserContext userContextWithUsername: userName
andTDBIndexing: indexingTdb];
[userContext ensureFolderTableExists];
[root setTableUrl: [userContext folderTableURL]];
names = [root toManyRelationshipKeys];
max = [names count];
for (count = 0; count < max; count++)