diff options
author | Graham Leggett <minfrin@apache.org> | 2010-10-20 00:53:41 +0200 |
---|---|---|
committer | Graham Leggett <minfrin@apache.org> | 2010-10-20 00:53:41 +0200 |
commit | 7cecbabda3fefb259c7fe4065c3446de8dec33a8 (patch) | |
tree | 56cc694f7de83c238df66e5017c1260111cd5efb /modules/ldap | |
parent | Avoid unnecessariy initialisation before we test handler name. (diff) | |
download | apache2-7cecbabda3fefb259c7fe4065c3446de8dec33a8.tar.xz apache2-7cecbabda3fefb259c7fe4065c3446de8dec33a8.zip |
Avoid unnecessariy initialisation before we test ldap-status handler name.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1024453 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'modules/ldap')
-rw-r--r-- | modules/ldap/util_ldap.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/modules/ldap/util_ldap.c b/modules/ldap/util_ldap.c index 95a88be3ed..6f485b5a00 100644 --- a/modules/ldap/util_ldap.c +++ b/modules/ldap/util_ldap.c @@ -104,18 +104,20 @@ static void util_ldap_strdup (char **str, const char *newstr) */ static int util_ldap_handler(request_rec *r) { - util_ldap_state_t *st = (util_ldap_state_t *) - ap_get_module_config(r->server->module_config, - &ldap_module); + util_ldap_state_t *st; r->allowed |= (1 << M_GET); - if (r->method_number != M_GET) + if (r->method_number != M_GET) { return DECLINED; + } if (strcmp(r->handler, "ldap-status")) { return DECLINED; } + st = (util_ldap_state_t *) ap_get_module_config(r->server->module_config, + &ldap_module); + ap_set_content_type(r, "text/html; charset=ISO-8859-1"); if (r->header_only) |