X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=lib%2Fconfig.cc;h=503a0c8b585323dd59fad974b55ca47b7399fad6;hb=0a32741fceb7778ced34064eacb7b5aac2c71638;hp=f61eb63699ce5c0114c18152d54401721efc6c46;hpb=fad2e7540bf9309bfb335650ded753e9ed085eff;p=notmuch diff --git a/lib/config.cc b/lib/config.cc index f61eb636..503a0c8b 100644 --- a/lib/config.cc +++ b/lib/config.cc @@ -435,11 +435,6 @@ _notmuch_config_load_from_file (notmuch_database_t *notmuch, for (gchar **keys_p = keys; *keys_p; keys_p++) { char *absolute_key = talloc_asprintf (notmuch, "%s.%s", *grp, *keys_p); char *normalized_val; - val = g_key_file_get_string (file, *grp, *keys_p, NULL); - if (! val) { - status = NOTMUCH_STATUS_FILE_ERROR; - goto DONE; - } /* If we opened from a given path, do not overwrite it */ if (strcmp (absolute_key, "database.path") == 0 && @@ -447,6 +442,12 @@ _notmuch_config_load_from_file (notmuch_database_t *notmuch, notmuch->xapian_db) continue; + val = g_key_file_get_string (file, *grp, *keys_p, NULL); + if (! val) { + status = NOTMUCH_STATUS_FILE_ERROR; + goto DONE; + } + normalized_val = _expand_path (notmuch, absolute_key, val); _notmuch_string_map_set (notmuch->config, absolute_key, normalized_val); g_free (val); @@ -596,6 +597,8 @@ _notmuch_config_key_to_string (notmuch_config_key_t key) return "user.name"; case NOTMUCH_CONFIG_AUTOCOMMIT: return "database.autocommit"; + case NOTMUCH_CONFIG_EXTRA_HEADERS: + return "show.extra_headers"; default: return NULL; } @@ -643,6 +646,7 @@ _notmuch_config_default (notmuch_database_t *notmuch, notmuch_config_key_t key) return ""; case NOTMUCH_CONFIG_AUTOCOMMIT: return "8000"; + case NOTMUCH_CONFIG_EXTRA_HEADERS: case NOTMUCH_CONFIG_HOOK_DIR: case NOTMUCH_CONFIG_BACKUP_DIR: case NOTMUCH_CONFIG_OTHER_EMAIL: