expcov report - Generated Sat Oct 15 21:39:18 2016

 Index  Statistics  Last 
Directory./modules/mappers
Filenamemod_dir.c
ModifiedTue Feb 12 21:27:06 2013

Pass Half Fail Excluded Total
Function
2
25.00%
6
75.00%
0
0.00%
8
100%
Expressions
4
2.52%
155
97.48%
0
0.00%
159
100%
Conditions
0
0.00%
0
0.00%
52
100.00%
0
0.00%
52
100%
MC/DC
0
0.00%
28
100.00%
0
0.00%
28
100%
Branches

if
0
0.00%
0
0.00%
22
100.00%
0
0.00%
22
100%
for
0
0.00%
0
0.00%
1
100.00%
0
0.00%
1
100%
while
0
0.00%
0
0.00%
0
0.00%
0
0.00%
0
100%
case
0
0.00%
0
0.00%
0
0.00%
0
0.00%
0
100%

1/* Licensed to the Apache Software Foundation (ASF) under one or more
2 * contributor license agreements.  See the NOTICE file distributed with
3 * this work for additional information regarding copyright ownership.
4 * The ASF licenses this file to You under the Apache License, Version 2.0
5 * (the "License"); you may not use this file except in compliance with
6 * the License.  You may obtain a copy of the License at
7 *
8 *     http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17/*
18 * mod_dir.c: handle default index files, and trailing-/ redirects
19 */
20
21#include "apr_strings.h"
22#include "ap_config.h"
23#include "httpd.h"
24#include "http_config.h"
25#include "http_core.h"
26#include "http_request.h"
27#include "http_protocol.h"
28#include "http_log.h"
29#include "http_main.h"
30#include "util_script.h"
31
32module AP_MODULE_DECLARE_DATA dir_module;
33
34typedef enum {
35    SLASH_OFF = 0,
36    SLASH_ON,
37    SLASH_UNSET
38} slash_cfg;
39
40typedef struct dir_config_struct {
41    apr_array_header_t *index_names;
42    slash_cfg do_slash;
43    const char *dflt;
44} dir_config_rec;
45
46#define DIR_CMD_PERMS OR_INDEXES
47
48static const char *add_index : call=0
a
dd_index(cmd_parms *cmd, void *dummy, const char *arg)
49{
50    dir_config_rec *d = dummy : modules/mappers/mod_dir.c line=48 column=52
d
ummy;
51
52    if : true=0, false=0
i
f (! : true=0, false=0
!
d : modules/mappers/mod_dir.c line=50 column=21
d
-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names) {
53        d : modules/mappers/mod_dir.c line=50 column=21
d
-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names = : enter=0, leave=0
=
 apr_array_make : enter=0, leave=0

apr_array_make : /usr/include/apr-1/apr_tables.h line=111 column=35
a
pr_array_make(cmd : modules/mappers/mod_dir.c line=48 column=41
c
md-> : enter=0, leave=0
-
>pool : include/http_config.h line=291 column=17
p
ool, 2, sizeof(char *));
54    }
55    *(const char **)apr_array_push : enter=0, leave=0

apr_array_push : /usr/include/apr-1/apr_tables.h line=121 column=21
a
pr_array_push(d : modules/mappers/mod_dir.c line=50 column=21
d
-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names) = : enter=0, leave=0
=
 arg : modules/mappers/mod_dir.c line=48 column=71
a
rg;
56    return : pass=0
r
eturn NULL;
57}
58
59static const char *configure_slash : call=0
c
onfigure_slash(cmd_parms *cmd, void *d_, int arg)
60{
61    dir_config_rec *d = d_ : modules/mappers/mod_dir.c line=59 column=58
d
_;
62
63    d : modules/mappers/mod_dir.c line=61 column=21
d
-> : enter=0, leave=0
-
>do_slash : modules/mappers/mod_dir.c line=42 column=15
d
o_slash = : enter=0, leave=0
=
 arg : modules/mappers/mod_dir.c line=59 column=66
a
rg conditional operator : true=0, false=0
?
 SLASH_ON : modules/mappers/mod_dir.c line=36 column=5
S
LASH_ON : SLASH_OFF : modules/mappers/mod_dir.c line=35 column=5
S
LASH_OFF;
64    return : pass=0
r
eturn NULL;
65}
66
67static const command_rec dir_cmds[] =
68{
69    AP_INIT_TAKE1("FallbackResource", ap_set_string_slot : include/http_config.h line=478 column=33
a
p_set_string_slot,
70                  (void*)APR_OFFSETOF(dir_config_rec, dflt : modules/mappers/mod_dir.c line=43 column=17
d
flt),
71                  DIR_CMD_PERMS, "Set a default handler"),
72    AP_INIT_ITERATE("DirectoryIndex", add_index : modules/mappers/mod_dir.c line=48 column=20
a
dd_index, NULL, DIR_CMD_PERMS,
73                    "a list of file names"),
74    AP_INIT_FLAG("DirectorySlash", configure_slash : modules/mappers/mod_dir.c line=59 column=20
c
onfigure_slash, NULL, DIR_CMD_PERMS,
75                 "On or Off"),
76    {NULL}
77};
78
79static void *create_dir_config : call=1
c
reate_dir_config(apr_pool_t *p, char *dummy)
80{
81    dir_config_rec *new = apr_pcalloc(p : modules/mappers/mod_dir.c line=79 column=44
p
, sizeof(dir_config_rec));
82
83    new : modules/mappers/mod_dir.c line=81 column=21
n
ew-> : enter=1, leave=1
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names = : enter=1, leave=1
=
 NULL;
84    new : modules/mappers/mod_dir.c line=81 column=21
n
ew-> : enter=1, leave=1
-
>do_slash : modules/mappers/mod_dir.c line=42 column=15
d
o_slash = : enter=1, leave=1
=
 SLASH_UNSET : modules/mappers/mod_dir.c line=37 column=5
S
LASH_UNSET;
85    return : pass=1
r
eturn (void *) new : modules/mappers/mod_dir.c line=81 column=21
n
ew;
86}
87
88static void *merge_dir_configs : call=0
m
erge_dir_configs(apr_pool_t *p, void *basev, void *addv)
89{
90    dir_config_rec *new = apr_pcalloc(p : modules/mappers/mod_dir.c line=88 column=44
p
, sizeof(dir_config_rec));
91    dir_config_rec *base = (dir_config_rec *)basev : modules/mappers/mod_dir.c line=88 column=53
b
asev;
92    dir_config_rec *add = (dir_config_rec *)addv : modules/mappers/mod_dir.c line=88 column=66
a
ddv;
93
94    new : modules/mappers/mod_dir.c line=90 column=21
n
ew-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names = : enter=0, leave=0
=
 add : modules/mappers/mod_dir.c line=92 column=21
a
dd-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names conditional operator : true=0, false=0
?
 add : modules/mappers/mod_dir.c line=92 column=21
a
dd-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names : base : modules/mappers/mod_dir.c line=91 column=21
b
ase-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names;
95    new : modules/mappers/mod_dir.c line=90 column=21
n
ew-> : enter=0, leave=0
-
>do_slash : modules/mappers/mod_dir.c line=42 column=15
d
o_slash = : enter=0, leave=0
=
96        (add : modules/mappers/mod_dir.c line=92 column=21
a
dd-> : enter=0, leave=0
-
>do_slash : modules/mappers/mod_dir.c line=42 column=15
d
o_slash == : true=0, false=0
=
SLASH_UNSET : modules/mappers/mod_dir.c line=37 column=5
S
LASH_UNSET) conditional operator : true=0, false=0
?
 base : modules/mappers/mod_dir.c line=91 column=21
b
ase-> : enter=0, leave=0
-
>do_slash : modules/mappers/mod_dir.c line=42 column=15
d
o_slash : add : modules/mappers/mod_dir.c line=92 column=21
a
dd-> : enter=0, leave=0
-
>do_slash : modules/mappers/mod_dir.c line=42 column=15
d
o_slash;
97    new : modules/mappers/mod_dir.c line=90 column=21
n
ew-> : enter=0, leave=0
-
>dflt : modules/mappers/mod_dir.c line=43 column=17
d
flt = : enter=0, leave=0
=
 add : modules/mappers/mod_dir.c line=92 column=21
a
dd-> : enter=0, leave=0
-
>dflt : modules/mappers/mod_dir.c line=43 column=17
d
flt conditional operator : true=0, false=0
?
 add : modules/mappers/mod_dir.c line=92 column=21
a
dd-> : enter=0, leave=0
-
>dflt : modules/mappers/mod_dir.c line=43 column=17
d
flt : base : modules/mappers/mod_dir.c line=91 column=21
b
ase-> : enter=0, leave=0
-
>dflt : modules/mappers/mod_dir.c line=43 column=17
d
flt;
98    return : pass=0
r
eturn new : modules/mappers/mod_dir.c line=90 column=21
n
ew;
99}
100
101static int fixup_dflt : call=0
f
ixup_dflt(request_rec *r)
102{
103    dir_config_rec *d = ap_get_module_config(r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>per_dir_config : include/httpd.h line=977 column=30
p
er_dir_config, &dir_module : modules/mappers/mod_dir.c line=32 column=31
d
ir_module);
104    const char *name_ptr;
105    request_rec *rr;
106    int error_notfound = 0;
107
108    name_ptr : modules/mappers/mod_dir.c line=104 column=17
n
ame_ptr = : pass=0
=
 d : modules/mappers/mod_dir.c line=103 column=21
d
-> : enter=0, leave=0
-
>dflt : modules/mappers/mod_dir.c line=43 column=17
d
flt;
109    if : true=0, false=0
i
f ((name_ptr : modules/mappers/mod_dir.c line=104 column=17
n
ame_ptr == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
= NULL) || : true=0, false=0
|
! : true=0, false=0
MC/DC independently affect : true=0, false=0
!TF
(strcasecmp : enter=0, leave=0

strcasecmp : /usr/include/string.h line=536 column=12
s
trcasecmp(name_ptr : modules/mappers/mod_dir.c line=104 column=17
n
ame_ptr,"disabled"))) {
110        return : pass=0
r
eturn DECLINED;
111    }
112    /* XXX: if DefaultHandler points to something that doesn't exist,
113     * this may recurse until it hits the limit for internal redirects
114     * before returning an Internal Server Error.
115     */
116
117    /* The logic of this function is basically cloned and simplified
118     * from fixup_dir below.  See the comments there.
119     */
120    if : true=0, false=0
i
f (r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>args : include/httpd.h line=955 column=11
a
rgs != : true=0, false=0
!
= NULL) {
121        name_ptr : modules/mappers/mod_dir.c line=104 column=17
n
ame_ptr = : pass=0
=
 apr_pstrcat : enter=0, leave=0

apr_pstrcat : /usr/include/apr-1/apr_strings.h line=139 column=28
a
pr_pstrcat(r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, name_ptr : modules/mappers/mod_dir.c line=104 column=17
n
ame_ptr, "?", r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>args : include/httpd.h line=955 column=11
a
rgs, NULL);
122    }
123    rr : modules/mappers/mod_dir.c line=105 column=18
r
= : pass=0
=
 ap_sub_req_lookup_uri : enter=0, leave=0

ap_sub_req_lookup_uri : include/http_request.h line=71 column=27
a
p_sub_req_lookup_uri(name_ptr : modules/mappers/mod_dir.c line=104 column=17
n
ame_ptr, r : modules/mappers/mod_dir.c line=101 column=36
r
r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>output_filters : include/httpd.h line=990 column=25
o
utput_filters);
124    if : true=0, false=0
i
f (rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
= HTTP_OK
125        && : true=0, false=0
&
& (   (rr : modules/mappers/mod_dir.c line=105 column=18
r
rMC/DC independently affect : true=0, false=0
-> : enter=0, leave=0
-TF
>handler : include/httpd.h line=919 column=17
h
andler && : true=0, false=0
&
! : true=0, false=0
MC/DC independently affect : true=0, false=0
!TF
strcmp : enter=0, leave=0

strcmp : /usr/include/string.h line=143 column=12
s
trcmp(rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>handler : include/httpd.h line=919 column=17
h
andler, "proxy-server"))
126            || : true=0, false=0
|
rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>finfo : include/httpd.h line=957 column=17
f
info.filetype : /usr/include/apr-1/apr_file_info.h line=186 column=20 filetype == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
APR_REG : /usr/include/apr-1/apr_file_info.h line=64 column=5 APR_REG)) {
127        ap_internal_fast_redirect : enter=0, leave=0

ap_internal_fast_redirect : include/http_request.h line=175 column=18
a
p_internal_fast_redirect(rr : modules/mappers/mod_dir.c line=105 column=18
r
r, r : modules/mappers/mod_dir.c line=101 column=36
r
);
128        return : pass=0
r
eturn OK;
129    }
130    else if : true=0, false=0
i
f (ap_is_HTTP_REDIRECT(rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus)) {
131
132        apr_pool_join(r->pool, rr->pool);
133        r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>notes : include/httpd.h line=910 column=18
n
otes = : enter=0, leave=0
=
 apr_table_overlay : enter=0, leave=0

apr_table_overlay : /usr/include/apr-1/apr_tables.h line=346 column=28
a
pr_table_overlay(r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>notes : include/httpd.h line=910 column=18
n
otes, rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>notes : include/httpd.h line=910 column=18
n
otes);
134        r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>headers_out : include/httpd.h line=903 column=18
h
eaders_out = : enter=0, leave=0
=
 apr_table_overlay : enter=0, leave=0

apr_table_overlay : /usr/include/apr-1/apr_tables.h line=346 column=28
a
pr_table_overlay(r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>headers_out : include/httpd.h line=903 column=18
h
eaders_out,
135                                           rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>headers_out : include/httpd.h line=903 column=18
h
eaders_out);
136        r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>err_headers_out : include/httpd.h line=906 column=18
e
rr_headers_out = : enter=0, leave=0
=
 apr_table_overlay : enter=0, leave=0

apr_table_overlay : /usr/include/apr-1/apr_tables.h line=346 column=28
a
pr_table_overlay(r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, r : modules/mappers/mod_dir.c line=101 column=36
r
-> : enter=0, leave=0
-
>err_headers_out : include/httpd.h line=906 column=18
e
rr_headers_out,
137                                               rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>err_headers_out : include/httpd.h line=906 column=18
e
rr_headers_out);
138        error_notfound : modules/mappers/mod_dir.c line=106 column=9
e
rror_notfound = : pass=0
=
 rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus;
139    }
140    else if : true=0, false=0
i
f (rr : modules/mappers/mod_dir.c line=105 column=18
r
rMC/DC independently affect : true=0, false=0
-> : enter=0, leave=0
-TF
>status : include/httpd.h line=822 column=9
s
tatus && : true=0, false=0
&
rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus != : true=0, false=0
MC/DC independently affect : true=0, false=0
!TF
= HTTP_NOT_FOUND
141             && : true=0, false=0
&
rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus != : true=0, false=0
MC/DC independently affect : true=0, false=0
!TF
= HTTP_OK) {
142        error_notfound : modules/mappers/mod_dir.c line=106 column=9
e
rror_notfound = : pass=0
=
 rr : modules/mappers/mod_dir.c line=105 column=18
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus;
143    }
144
145    ap_destroy_sub_req : enter=0, leave=0

ap_destroy_sub_req : include/http_request.h line=144 column=18
a
p_destroy_sub_req(rr : modules/mappers/mod_dir.c line=105 column=18
r
r);
146    if : true=0, false=0
i
f (error_notfound : modules/mappers/mod_dir.c line=106 column=9
e
rror_notfound) {
147        return : pass=0
r
eturn error_notfound : modules/mappers/mod_dir.c line=106 column=9
e
rror_notfound;
148    }
149
150    /* nothing for us to do, pass on through */
151    return : pass=0
r
eturn DECLINED;
152}
153static int fixup_dir : call=0
f
ixup_dir(request_rec *r)
154{
155    dir_config_rec *d;
156    char *dummy_ptr[1];
157    char **names_ptr;
158    int num_names;
159    int error_notfound = 0;
160
161    /* In case mod_mime wasn't present, and no handler was assigned. */
162    if : true=0, false=0
i
f (! : true=0, false=0
!
r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>handler : include/httpd.h line=919 column=17
h
andler) {
163        r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>handler : include/httpd.h line=919 column=17
h
andler = : enter=0, leave=0
=
 DIR_MAGIC_TYPE;
164    }
165
166    /* Never tolerate path_info on dir requests */
167    if : true=0, false=0
i
f (r : modules/mappers/mod_dir.c line=153 column=35
r
MC/DC independently affect : true=0, false=0
-> : enter=0, leave=0
-TF
>path_info : include/httpd.h line=953 column=11
p
ath_info && : true=0, false=0
&
MC/DC independently affect : true=0, false=0
* dereference : enter=0, leave=0
*TF
r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>path_info : include/httpd.h line=953 column=11
p
ath_info) {
168        return : pass=0
r
eturn DECLINED;
169    }
170
171    d : modules/mappers/mod_dir.c line=155 column=21
d
 = : pass=0
=
 (dir_config_rec *)ap_get_module_config(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>per_dir_config : include/httpd.h line=977 column=30
p
er_dir_config,
172                                               &dir_module : modules/mappers/mod_dir.c line=32 column=31
d
ir_module);
173
174    /* Redirect requests that are not '/' terminated */
175    if : true=0, false=0
i
f (r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>uri : include/httpd.h line=946 column=11
u
ri[] : enter=0, leave=0
[
0] == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
= '\0' || : true=0, false=0
|
r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>uri : include/httpd.h line=946 column=11
u
ri[] : enter=0, leave=0
[
strlen : enter=0, leave=0

strlen : /usr/include/string.h line=399 column=15
s
trlen(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>uri : include/httpd.h line=946 column=11
u
ri) - : pass=0
-
 1] != : true=0, false=0
MC/DC independently affect : true=0, false=0
!TF
= '/')
176    {
177        char *ifile;
178
179        if : true=0, false=0
i
f (! : true=0, false=0
!
d : modules/mappers/mod_dir.c line=155 column=21
d
-> : enter=0, leave=0
-
>do_slash : modules/mappers/mod_dir.c line=42 column=15
d
o_slash) {
180            return : pass=0
r
eturn DECLINED;
181        }
182
183        /* Only redirect non-get requests if we have no note to warn
184         * that this browser cannot handle redirs on non-GET requests
185         * (such as Microsoft's WebFolders).
186         */
187        if : true=0, false=0
i
f ((r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>method_number : include/httpd.h line=831 column=9
m
ethod_number != : true=0, false=0
MC/DC independently affect : true=0, false=0
!TF
= M_GET)
188                && : true=0, false=0
&
MC/DC independently affect : true=0, false=0
apr_table_get : enter=0, leave=0

apr_table_get : /usr/include/apr-1/apr_tables.h line=258 column=27
aTF
pr_table_get(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>subprocess_env : include/httpd.h line=908 column=18
s
ubprocess_env, "redirect-carefully")) {
189            return : pass=0
r
eturn DECLINED;
190        }
191
192        if : true=0, false=0
i
f (r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>args : include/httpd.h line=955 column=11
a
rgs != : true=0, false=0
!
= NULL) {
193            ifile : modules/mappers/mod_dir.c line=177 column=15
i
file = : pass=0
=
 apr_pstrcat : enter=0, leave=0

apr_pstrcat : /usr/include/apr-1/apr_strings.h line=139 column=28
a
pr_pstrcat(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, ap_escape_uri(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>uri : include/httpd.h line=946 column=11
u
ri),
194                                "/", "?", r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>args : include/httpd.h line=955 column=11
a
rgs, NULL);
195        }
196        else {
197            ifile : modules/mappers/mod_dir.c line=177 column=15
i
file = : pass=0
=
 apr_pstrcat : enter=0, leave=0

apr_pstrcat : /usr/include/apr-1/apr_strings.h line=139 column=28
a
pr_pstrcat(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, ap_escape_uri(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>uri : include/httpd.h line=946 column=11
u
ri),
198                                "/", NULL);
199        }
200
201        apr_table_setn : enter=0, leave=0

apr_table_setn : /usr/include/apr-1/apr_tables.h line=282 column=19
a
pr_table_setn(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>headers_out : include/httpd.h line=903 column=18
h
eaders_out, "Location",
202                       ap_construct_url : enter=0, leave=0

ap_construct_url : include/http_core.h line=221 column=20
a
p_construct_url(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, ifile : modules/mappers/mod_dir.c line=177 column=15
i
file, r : modules/mappers/mod_dir.c line=153 column=35
r
));
203        return : pass=0
r
eturn HTTP_MOVED_PERMANENTLY;
204    }
205
206    if : true=0, false=0
i
f (strcmp : enter=0, leave=0

strcmp : /usr/include/string.h line=143 column=12
s
trcmp(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>handler : include/httpd.h line=919 column=17
h
andler, DIR_MAGIC_TYPE)) {
207        return : pass=0
r
eturn DECLINED;
208    }
209
210    if : true=0, false=0
i
f (d : modules/mappers/mod_dir.c line=155 column=21
d
-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names) {
211        names_ptr : modules/mappers/mod_dir.c line=157 column=12
n
ames_ptr = : pass=0
=
 (char **)d : modules/mappers/mod_dir.c line=155 column=21
d
-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names-> : enter=0, leave=0
-
>elts : /usr/include/apr-1/apr_tables.h line=62 column=11 elts;
212        num_names : modules/mappers/mod_dir.c line=158 column=9
n
um_names = : pass=0
=
 d : modules/mappers/mod_dir.c line=155 column=21
d
-> : enter=0, leave=0
-
>index_names : modules/mappers/mod_dir.c line=41 column=25
i
ndex_names-> : enter=0, leave=0
-
>nelts : /usr/include/apr-1/apr_tables.h line=58 column=9 nelts;
213    }
214    else {
215        dummy_ptr : modules/mappers/mod_dir.c line=156 column=11
d
ummy_ptr[0] = : enter=0, leave=0
=
 AP_DEFAULT_INDEX;
216        names_ptr : modules/mappers/mod_dir.c line=157 column=12
n
ames_ptr = : pass=0
=
 dummy_ptr : modules/mappers/mod_dir.c line=156 column=11
d
ummy_ptr;
217        num_names : modules/mappers/mod_dir.c line=158 column=9
n
um_names = : pass=0
=
 1;
218    }
219
220    for : true=0, false=0
f
or (; num_names : modules/mappers/mod_dir.c line=158 column=9
n
um_names; ++ : pass=0
+
+names_ptr : modules/mappers/mod_dir.c line=157 column=12
n
ames_ptr, -- : pass=0
-
-num_names : modules/mappers/mod_dir.c line=158 column=9
n
um_names) {
221        /* XXX: Is this name_ptr considered escaped yet, or not??? */
222        char *name_ptr = * dereference : enter=0, leave=0
*
names_ptr : modules/mappers/mod_dir.c line=157 column=12
n
ames_ptr;
223        request_rec *rr;
224
225        /* Once upon a time args were handled _after_ the successful redirect.
226         * But that redirect might then _refuse_ the given r->args, creating
227         * a nasty tangle.  It seems safer to consider the r->args while we
228         * determine if name_ptr is our viable index, and therefore set them
229         * up correctly on redirect.
230         */
231        if : true=0, false=0
i
f (r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>args : include/httpd.h line=955 column=11
a
rgs != : true=0, false=0
!
= NULL) {
232            name_ptr : modules/mappers/mod_dir.c line=222 column=15
n
ame_ptr = : pass=0
=
 apr_pstrcat : enter=0, leave=0

apr_pstrcat : /usr/include/apr-1/apr_strings.h line=139 column=28
a
pr_pstrcat(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, name_ptr : modules/mappers/mod_dir.c line=222 column=15
n
ame_ptr, "?", r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>args : include/httpd.h line=955 column=11
a
rgs, NULL);
233        }
234
235        rr : modules/mappers/mod_dir.c line=223 column=22
r
= : pass=0
=
 ap_sub_req_lookup_uri : enter=0, leave=0

ap_sub_req_lookup_uri : include/http_request.h line=71 column=27
a
p_sub_req_lookup_uri(name_ptr : modules/mappers/mod_dir.c line=222 column=15
n
ame_ptr, r : modules/mappers/mod_dir.c line=153 column=35
r
r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>output_filters : include/httpd.h line=990 column=25
o
utput_filters);
236
237        /* The sub request lookup is very liberal, and the core map_to_storage
238         * handler will almost always result in HTTP_OK as /foo/index.html
239         * may be /foo with PATH_INFO="/index.html", or even / with
240         * PATH_INFO="/foo/index.html". To get around this we insist that the
241         * the index be a regular filetype.
242         *
243         * Another reason is that the core handler also makes the assumption
244         * that if r->finfo is still NULL by the time it gets called, the
245         * file does not exist.
246         */
247        if : true=0, false=0
i
f (rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
= HTTP_OK
248            && : true=0, false=0
&
& (   (rr : modules/mappers/mod_dir.c line=223 column=22
r
rMC/DC independently affect : true=0, false=0
-> : enter=0, leave=0
-TF
>handler : include/httpd.h line=919 column=17
h
andler && : true=0, false=0
&
! : true=0, false=0
MC/DC independently affect : true=0, false=0
!TF
strcmp : enter=0, leave=0

strcmp : /usr/include/string.h line=143 column=12
s
trcmp(rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>handler : include/httpd.h line=919 column=17
h
andler, "proxy-server"))
249                || : true=0, false=0
|
rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>finfo : include/httpd.h line=957 column=17
f
info.filetype : /usr/include/apr-1/apr_file_info.h line=186 column=20 filetype == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
APR_REG : /usr/include/apr-1/apr_file_info.h line=64 column=5 APR_REG)) {
250            ap_internal_fast_redirect : enter=0, leave=0

ap_internal_fast_redirect : include/http_request.h line=175 column=18
a
p_internal_fast_redirect(rr : modules/mappers/mod_dir.c line=223 column=22
r
r, r : modules/mappers/mod_dir.c line=153 column=35
r
);
251            return : pass=0
r
eturn OK;
252        }
253
254        /* If the request returned a redirect, propagate it to the client */
255
256        if : true=0, false=0
i
f (ap_is_HTTP_REDIRECT(rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus)
257            || : true=0, false=0
|
| (rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
= HTTP_NOT_ACCEPTABLE && : true=0, false=0
&
num_names : modules/mappers/mod_dir.c line=158 column=9
n
um_names == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
= 1)
258            || : true=0, false=0
|
| (rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
= HTTP_UNAUTHORIZED && : true=0, false=0
&
num_names : modules/mappers/mod_dir.c line=158 column=9
n
um_names == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
= 1)) {
259
260            apr_pool_join(r->pool, rr->pool);
261            error_notfound : modules/mappers/mod_dir.c line=159 column=9
e
rror_notfound = : pass=0
=
 rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus;
262            r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>notes : include/httpd.h line=910 column=18
n
otes = : enter=0, leave=0
=
 apr_table_overlay : enter=0, leave=0

apr_table_overlay : /usr/include/apr-1/apr_tables.h line=346 column=28
a
pr_table_overlay(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>notes : include/httpd.h line=910 column=18
n
otes, rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>notes : include/httpd.h line=910 column=18
n
otes);
263            r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>headers_out : include/httpd.h line=903 column=18
h
eaders_out = : enter=0, leave=0
=
 apr_table_overlay : enter=0, leave=0

apr_table_overlay : /usr/include/apr-1/apr_tables.h line=346 column=28
a
pr_table_overlay(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>headers_out : include/httpd.h line=903 column=18
h
eaders_out,
264                                               rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>headers_out : include/httpd.h line=903 column=18
h
eaders_out);
265            r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>err_headers_out : include/httpd.h line=906 column=18
e
rr_headers_out = : enter=0, leave=0
=
 apr_table_overlay : enter=0, leave=0

apr_table_overlay : /usr/include/apr-1/apr_tables.h line=346 column=28
a
pr_table_overlay(r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, r : modules/mappers/mod_dir.c line=153 column=35
r
-> : enter=0, leave=0
-
>err_headers_out : include/httpd.h line=906 column=18
e
rr_headers_out,
266                                                   rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>err_headers_out : include/httpd.h line=906 column=18
e
rr_headers_out);
267            return : pass=0
r
eturn error_notfound : modules/mappers/mod_dir.c line=159 column=9
e
rror_notfound;
268        }
269
270        /* If the request returned something other than 404 (or 200),
271         * it means the module encountered some sort of problem. To be
272         * secure, we should return the error, rather than allow autoindex
273         * to create a (possibly unsafe) directory index.
274         *
275         * So we store the error, and if none of the listed files
276         * exist, we return the last error response we got, instead
277         * of a directory listing.
278         */
279        if : true=0, false=0
i
f (rr : modules/mappers/mod_dir.c line=223 column=22
r
rMC/DC independently affect : true=0, false=0
-> : enter=0, leave=0
-TF
>status : include/httpd.h line=822 column=9
s
tatus && : true=0, false=0
&
rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus != : true=0, false=0
MC/DC independently affect : true=0, false=0
!TF
= HTTP_NOT_FOUND
280                && : true=0, false=0
&
rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus != : true=0, false=0
MC/DC independently affect : true=0, false=0
!TF
= HTTP_OK) {
281            error_notfound : modules/mappers/mod_dir.c line=159 column=9
e
rror_notfound = : pass=0
=
 rr : modules/mappers/mod_dir.c line=223 column=22
r
r-> : enter=0, leave=0
-
>status : include/httpd.h line=822 column=9
s
tatus;
282        }
283
284        ap_destroy_sub_req : enter=0, leave=0

ap_destroy_sub_req : include/http_request.h line=144 column=18
a
p_destroy_sub_req(rr : modules/mappers/mod_dir.c line=223 column=22
r
r);
285    }
286
287    if : true=0, false=0
i
f (error_notfound : modules/mappers/mod_dir.c line=159 column=9
e
rror_notfound) {
288        return : pass=0
r
eturn error_notfound : modules/mappers/mod_dir.c line=159 column=9
e
rror_notfound;
289    }
290
291    /* nothing for us to do, pass on through */
292    return : pass=0
r
eturn DECLINED;
293}
294static int dir_fixups : call=0
d
ir_fixups(request_rec *r)
295{
296    if : true=0, false=0
i
f (r : modules/mappers/mod_dir.c line=294 column=36
r
-> : enter=0, leave=0
-
>finfo : include/httpd.h line=957 column=17
f
info.filetype : /usr/include/apr-1/apr_file_info.h line=186 column=20 filetype == : true=0, false=0
=
APR_DIR : /usr/include/apr-1/apr_file_info.h line=65 column=5 APR_DIR) {
297        /* serve up a directory */
298        return : pass=0
r
eturn fixup_dir : enter=0, leave=0

fixup_dir : modules/mappers/mod_dir.c line=153 column=12
f
ixup_dir(r : modules/mappers/mod_dir.c line=294 column=36
r
);
299    }
300    else if : true=0, false=0
i
f ((r : modules/mappers/mod_dir.c line=294 column=36
r
-> : enter=0, leave=0
-
>finfo : include/httpd.h line=957 column=17
f
info.filetype : /usr/include/apr-1/apr_file_info.h line=186 column=20 filetype == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
APR_NOFILE : /usr/include/apr-1/apr_file_info.h line=63 column=5 APR_NOFILE) && : true=0, false=0
&
& (r : modules/mappers/mod_dir.c line=294 column=36
r
-> : enter=0, leave=0
-
>handler : include/httpd.h line=919 column=17
h
andler == : true=0, false=0
MC/DC independently affect : true=0, false=0
=TF
= NULL)) {
301        /* No handler and nothing in the filesystem - use fallback */
302        return : pass=0
r
eturn fixup_dflt : enter=0, leave=0

fixup_dflt : modules/mappers/mod_dir.c line=101 column=12
f
ixup_dflt(r : modules/mappers/mod_dir.c line=294 column=36
r
);
303    }
304    return : pass=0
r
eturn DECLINED;
305}
306
307static void register_hooks : call=1
r
egister_hooks(apr_pool_t *p)
308{
309    ap_hook_fixups : enter=1, leave=1

ap_hook_fixups : modules/mappers/ line=206 column=1
a
p_hook_fixups(dir_fixups : modules/mappers/mod_dir.c line=294 column=12
d
ir_fixups,NULL,NULL,APR_HOOK_LAST);
310}
311
312module AP_MODULE_DECLARE_DATA dir_module = {
313    STANDARD20_MODULE_STUFF,
314    create_dir_config : modules/mappers/mod_dir.c line=79 column=14
c
reate_dir_config,          /* create per-directory config structure */
315    merge_dir_configs : modules/mappers/mod_dir.c line=88 column=14
m
erge_dir_configs,          /* merge per-directory config structures */
316    NULL,                       /* create per-server config structure */
317    NULL,                       /* merge per-server config structures */
318    dir_cmds : modules/mappers/mod_dir.c line=67 column=26
d
ir_cmds,                   /* command apr_table_t */
319    register_hooks : modules/mappers/mod_dir.c line=307 column=13
r
egister_hooks              /* register hooks */
320};
321[EOF]


Generated by expcov