]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
doveconf: Reorder if-branches
authorTimo Sirainen <timo.sirainen@open-xchange.com>
Wed, 16 Oct 2024 09:59:31 +0000 (12:59 +0300)
committerAki Tuomi <aki.tuomi@open-xchange.com>
Fri, 17 Jan 2025 08:40:01 +0000 (10:40 +0200)
src/config/doveconf.c

index 22d7b8bcde4d851397e84ec313bb374bac890674..4ada152f06372d92be19a47a8414615825bbe654 100644 (file)
@@ -1165,11 +1165,7 @@ int main(int argc, char *argv[])
        if ((ret == -1 && exec_args != NULL) || ret == 0 || ret == -2)
                i_fatal("%s", error);
 
-       if (dump_full && exec_args == NULL) {
-               ret2 = config_dump_full(config,
-                                       CONFIG_DUMP_FULL_DEST_STDOUT,
-                                       0, &import_environment);
-       } else if (dump_full) {
+       if (dump_full && exec_args != NULL) {
                int temp_fd = config_dump_full(config,
                                               CONFIG_DUMP_FULL_DEST_TEMPDIR,
                                               0, &import_environment);
@@ -1188,6 +1184,10 @@ int main(int argc, char *argv[])
                        i_fatal("execvp(%s) failed: %m", exec_args[0]);
                }
                ret2 = -1;
+       } else if (dump_full) {
+               ret2 = config_dump_full(config,
+                                       CONFIG_DUMP_FULL_DEST_STDOUT,
+                                       0, &import_environment);
        } else if (setting_name_filters != NULL) {
                ret2 = 0;
                /* ignore settings-check failures in configuration. this allows