summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/settings.c2
-rw-r--r--src/lib-config/set.c6
2 files changed, 6 insertions, 2 deletions
diff --git a/src/core/settings.c b/src/core/settings.c
index 9c0999c9..6959453a 100644
--- a/src/core/settings.c
+++ b/src/core/settings.c
@@ -323,6 +323,7 @@ static void init_configfile(void)
g_free(str);
mainconfig = parse_configfile(NULL);
+ config_last_modifycounter = mainconfig->modifycounter;
/* any errors? */
if (config_last_error(mainconfig) != NULL) {
@@ -365,6 +366,7 @@ int settings_reread(const char *fname)
config_close(mainconfig);
mainconfig = tempconfig;
+ config_last_modifycounter = mainconfig->modifycounter;
signal_emit("setup changed", 0);
signal_emit("setup reread", 0);
diff --git a/src/lib-config/set.c b/src/lib-config/set.c
index 342d2b70..e0d3cf08 100644
--- a/src/lib-config/set.c
+++ b/src/lib-config/set.c
@@ -104,9 +104,11 @@ void config_node_set_str(CONFIG_REC *rec, CONFIG_NODE *parent, const char *key,
return;
}
- if (node != NULL)
+ if (node != NULL) {
+ if (strcmp(node->value, value) == 0)
+ return;
g_free(node->value);
- else {
+ } else {
node = g_new0(CONFIG_NODE, 1);
parent->value = g_slist_append(parent->value, node);