lib/mu-store: rework implementation

* mu-store.h, mu-store-read.cc, mu-store-write.cc, mu-store-priv.hh have been reworked
   in mu-store.{cc,hh}, it the mix of c/c++ improved
 * update all the dependent modules
 * make it easier to upgrade an database in place (without user intervention)
 * remove the xbatch-size option
This commit is contained in:
Dirk-Jan C. Binnema
2019-07-28 14:12:06 +03:00
parent b7cda29b96
commit 83d6484f86
14 changed files with 1393 additions and 1947 deletions

View File

@ -25,12 +25,13 @@
#include <errno.h>
#include <stdlib.h>
#include <ctype.h>
#include <inttypes.h>
#include <gmime/gmime.h>
#include "mu-util.h"
#include "mu-str.h"
#include "mu-maildir.h"
#include "mu-store.h"
#include "mu-store.hh"
#include "mu-msg-priv.h"
static gboolean init_file_metadata (MuMsgFile *self, const char* path,
@ -650,7 +651,7 @@ get_msgid (MuMsgFile *self, gboolean *do_free)
return (char*)msgid;
} else { /* if there is none, fake it */
*do_free = TRUE;
return g_strdup_printf ("%s@fake-msgid",
return g_strdup_printf ("%016 " PRIx64 "@fake-msgid",
mu_util_get_hash (self->_path));
}
}