** Fix for bug #543569
authorSrinivasa Ragavan <sragavan@novell.com>
Fri, 25 Jul 2008 05:35:47 +0000 (05:35 +0000)
committerSrinivasa Ragavan <sragavan@src.gnome.org>
Fri, 25 Jul 2008 05:35:47 +0000 (05:35 +0000)
2008-07-25  Srinivasa Ragavan  <sragavan@novell.com>

** Fix for bug #543569

* camel/camel-store.c: Recreate cache, if it was blown.

svn path=/trunk/; revision=9190

camel/ChangeLog
camel/camel-store.c

index 95b0023..8f1aafa 100644 (file)
@@ -1,4 +1,10 @@
 2008-07-25  Srinivasa Ragavan  <sragavan@novell.com>
+
+       ** Fix for bug #543569
+
+       * camel/camel-store.c: Recreate cache, if it was blown.
+
+2008-07-25  Srinivasa Ragavan  <sragavan@novell.com>
        
        ** Reverse the meaning of debug/free safe handlers. Let it crash now, than
        on a production build. We can fix it now. It would be turned off for a
index 21c727f..e550015 100644 (file)
@@ -222,6 +222,11 @@ construct (CamelService *service, CamelSession *session,
                g_free (store_path);
        }
 
+       if (!g_file_test(service->url->path, G_FILE_TEST_EXISTS)) {
+               /* Cache might be blown. Recreate. */
+               g_mkdir_with_parents (service->url->path, S_IRWXU);
+       }
+
        store->cdb = camel_db_open (store_db_path, ex);
        printf("store_db_path %s\n", store_db_path);
        if (camel_exception_is_set (ex)) {