]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-storage: Check for mail_plugin_dir existence only in config binary.
authorTimo Sirainen <tss@iki.fi>
Tue, 13 Apr 2010 10:24:31 +0000 (13:24 +0300)
committerTimo Sirainen <tss@iki.fi>
Tue, 13 Apr 2010 10:24:31 +0000 (13:24 +0300)
Other binaries may already have chrooted when the check is done.

--HG--
branch : HEAD

src/lib-storage/mail-storage-settings.c

index 05d91c95c05b1eff3c002ce99acd9959cc5087c8..98b16838124426e3c8d408b5b9c286bc5a1dc967 100644 (file)
@@ -382,14 +382,13 @@ static bool namespace_settings_check(void *_set, pool_t pool ATTR_UNUSED,
 }
 
 static bool mail_user_settings_check(void *_set, pool_t pool ATTR_UNUSED,
-                                    const char **error_r)
+                                    const char **error_r ATTR_UNUSED)
 {
        struct mail_user_settings *set = _set;
 
 #ifndef CONFIG_BINARY
        fix_base_path(set, pool, &set->auth_socket_path);
-#endif
-
+#else
        if (*set->mail_plugins != '\0' &&
            access(set->mail_plugin_dir, R_OK | X_OK) < 0) {
                *error_r = t_strdup_printf(
@@ -397,6 +396,7 @@ static bool mail_user_settings_check(void *_set, pool_t pool ATTR_UNUSED,
                        set->mail_plugin_dir);
                return FALSE;
        }
+#endif
        return TRUE;
 }
 /* </settings checks> */