]> git.ipfire.org Git - thirdparty/apache/httpd.git/commitdiff
mod_proxy_wstunnel: follow up to r1885239: use ap_find_linked_module().
authorYann Ylavic <ylavic@apache.org>
Thu, 7 Jan 2021 17:16:19 +0000 (17:16 +0000)
committerYann Ylavic <ylavic@apache.org>
Thu, 7 Jan 2021 17:16:19 +0000 (17:16 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1885244 13f79535-47bb-0310-9956-ffa450edef68

modules/proxy/mod_proxy_wstunnel.c

index e8750294062f297a6b0aaf28181c944e28767ae8..caf79e784d0723ae5364671fab1958fbb65d7d8b 100644 (file)
@@ -452,17 +452,8 @@ static const char * proxyws_set_asynch_delay(cmd_parms *cmd, void *conf, const c
 static int proxy_wstunnel_post_config(apr_pool_t *pconf, apr_pool_t *plog,
                                       apr_pool_t *ptemp, server_rec *s)
 {
-    fallback_to_mod_proxy_http = 0;
-    if (ap_state_query(AP_SQ_MAIN_STATE) != AP_SQ_MS_CREATE_PRE_CONFIG) {
-        apr_size_t i = 0;
-        const module *mod;
-        while ((mod = ap_loaded_modules[i++])) {
-            if (strcmp(mod->name, "mod_proxy_http.c") == 0) {
-                fallback_to_mod_proxy_http = 1;
-                break;
-            }
-        }
-    }
+    fallback_to_mod_proxy_http =
+        (ap_find_linked_module("mod_proxy_http.c") != NULL);
 
     return OK;
 }