]> source.dussan.org Git - rspamd.git/commitdiff
[Minor] Well, I've said `mirrors`!
authorVsevolod Stakhov <vsevolod@rspamd.com>
Wed, 30 Mar 2022 20:08:00 +0000 (21:08 +0100)
committerVsevolod Stakhov <vsevolod@rspamd.com>
Wed, 30 Mar 2022 20:08:00 +0000 (21:08 +0100)
src/rspamd_proxy.c

index bdf3e1a14e10ddbea53238a1ed0b4438a127bb18..d875c0efe4faee59b6cb107a99b7cafccafc4ed2 100644 (file)
@@ -506,6 +506,15 @@ rspamd_proxy_parse_mirror (rspamd_mempool_t *pool,
                return FALSE;
        }
 
+       if (!rspamd_config_is_enabled_from_ucl (pool, obj)) {
+               /* Upstream is valid but disabled */
+               msg_info_pool_check("upstream %s is disabled",
+                               ucl_object_lookup (obj, "name") ?
+                               ucl_object_tostring(ucl_object_lookup (obj, "name")) :
+                               ucl_object_key (obj));
+               return TRUE;
+       }
+
        up = rspamd_mempool_alloc0 (pool, sizeof (*up));
 
        elt = ucl_object_lookup (obj, "name");