From 66abc53fd09f7828efdce2a716de9c31f4c4a3d4 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Ond=C5=99ej=20Sur=C3=BD?= Date: Mon, 21 Jun 2010 17:03:40 +0200 Subject: [PATCH] Fix code in fixups --- mod_vhost_ldap.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/mod_vhost_ldap.c b/mod_vhost_ldap.c index e622191..3ac5b4f 100644 --- a/mod_vhost_ldap.c +++ b/mod_vhost_ldap.c @@ -716,12 +716,13 @@ static ap_unix_identity_t *mod_vhost_ldap_get_suexec_id_doer(const request_rec * static int mod_vhost_ldap_fixups(request_rec *r) { char *docroot = - apr_table_get(r->notes, "vhost-document-root"); + apr_table_get(r->notes, "vhost-document-root"); - if (docroot != NULL) - return set_document_root(r, ); - else - return DECLINED; + /* If we don't have DocumentRoot in notes then do nothing */ + if (docroot == NULL) + return DECLINED; + + return set_document_root(r, docroot); } static void -- 2.45.1