X-Git-Url: https://git.cworth.org/git?p=notmuch;a=blobdiff_plain;f=lib%2Fopen.cc;h=1ca69665c4e446ce4023b90713a86376c91310ee;hp=3325e72506cb3023911c870056265ef63b305fd5;hb=c84ccb70f3ed2b2228346499b5110311039a0ecf;hpb=b580009e2bc69efb019983bf2f7dc5052c19545a diff --git a/lib/open.cc b/lib/open.cc index 3325e725..1ca69665 100644 --- a/lib/open.cc +++ b/lib/open.cc @@ -324,24 +324,6 @@ _set_database_path (notmuch_database_t *notmuch, _notmuch_config_cache (notmuch, NOTMUCH_CONFIG_DATABASE_PATH, path); } -static void -_init_libs () -{ - - static int initialized = 0; - - /* Initialize the GLib type system and threads */ -#if ! GLIB_CHECK_VERSION (2, 35, 1) - g_type_init (); -#endif - - /* Initialize gmime */ - if (! initialized) { - g_mime_init (); - initialized = 1; - } -} - static void _load_database_state (notmuch_database_t *notmuch) { @@ -515,7 +497,7 @@ notmuch_database_open_with_config (const char *database_path, GKeyFile *key_file = NULL; bool split = false; - _init_libs (); + _notmuch_init (); notmuch = _alloc_notmuch (); if (! notmuch) { @@ -612,7 +594,7 @@ notmuch_database_create_with_config (const char *database_path, int err; bool split = false; - _init_libs (); + _notmuch_init (); notmuch = _alloc_notmuch (); if (! notmuch) { @@ -808,7 +790,7 @@ notmuch_database_load_config (const char *database_path, GKeyFile *key_file = NULL; bool split = false; - _init_libs (); + _notmuch_init (); notmuch = _alloc_notmuch (); if (! notmuch) {