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

 Index  Statistics  Last 
Directory./server
Filenameutil_xml.c
ModifiedSat Jun 6 01:50:47 2015

Pass Half Fail Excluded Total
Function
0
0.00%
1
100.00%
0
0.00%
1
100%
Expressions
0
0.00%
57
100.00%
0
0.00%
57
100%
Conditions
0
0.00%
0
0.00%
7
100.00%
0
0.00%
7
100%
MC/DC
0
0.00%
2
100.00%
0
0.00%
2
100%
Branches

if
0
0.00%
0
0.00%
8
100.00%
0
0.00%
8
100%
for
0
0.00%
0
0.00%
1
100.00%
0
0.00%
1
100%
while
0
0.00%
0
0.00%
1
100.00%
0
0.00%
1
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#include "apr_xml.h"
18
19#include "httpd.h"
20#include "http_protocol.h"
21#include "http_log.h"
22#include "http_core.h"
23
24#include "util_charset.h"
25#include "util_xml.h"
26
27
28/* used for reading input blocks */
29#define READ_BLOCKSIZE 2048
30
31
32AP_DECLARE(int) ap_xml_parse_input : call=0
a
p_xml_parse_input(request_rec * r, apr_xml_doc **pdoc)
33{
34    apr_xml_parser *parser;
35    apr_bucket_brigade *brigade;
36    int seen_eos;
37    apr_status_t status;
38    char errbuf[200];
39    apr_size_t total_read = 0;
40    apr_size_t limit_xml_body = ap_get_limit_xml_body : enter=0, leave=0

ap_get_limit_xml_body : include/http_core.h line=258 column=20
a
p_get_limit_xml_body(r : server/util_xml.c line=32 column=50
r
);
41    int result = HTTP_BAD_REQUEST;
42
43    parser : server/util_xml.c line=34 column=21
p
arser = : pass=0
=
 apr_xml_parser_create : enter=0, leave=0

apr_xml_parser_create : /usr/include/apr-1/apr_xml.h line=215 column=31
a
pr_xml_parser_create(r : server/util_xml.c line=32 column=50
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool);
44    brigade : server/util_xml.c line=35 column=25
b
rigade = : pass=0
=
 apr_brigade_create : enter=0, leave=0

apr_brigade_create : /usr/include/apr-1/apr_buckets.h line=658 column=35
a
pr_brigade_create(r : server/util_xml.c line=32 column=50
r
-> : enter=0, leave=0
-
>pool : include/httpd.h line=780 column=17
p
ool, r : server/util_xml.c line=32 column=50
r
-> : enter=0, leave=0
-
>connection : include/httpd.h line=782 column=15
c
onnection-> : enter=0, leave=0
-
>bucket_alloc : include/httpd.h line=1103 column=32
b
ucket_alloc);
45
46    seen_eos : server/util_xml.c line=36 column=9
s
een_eos = : pass=0
=
 0;
47    total_read : server/util_xml.c line=39 column=16
t
otal_read = : pass=0
=
 0;
48
49    do {
50        apr_bucket *bucket;
51
52        /* read the body, stuffing it into the parser */
53        status : server/util_xml.c line=37 column=18
s
tatus = : pass=0
=
 ap_get_brigade : enter=0, leave=0

ap_get_brigade : include/util_filter.h line=298 column=26
a
p_get_brigade(r : server/util_xml.c line=32 column=50
r
-> : enter=0, leave=0
-
>input_filters : include/httpd.h line=992 column=25
i
nput_filters, brigade : server/util_xml.c line=35 column=25
b
rigade,
54                                AP_MODE_READBYTES : include/util_filter.h line=52 column=5
A
P_MODE_READBYTES, APR_BLOCK_READ : /usr/include/apr-1/apr_buckets.h line=58 column=5 APR_BLOCK_READ,
55                                READ_BLOCKSIZE);
56
57        if : true=0, false=0
i
f (status : server/util_xml.c line=37 column=18
s
tatus != : true=0, false=0
!
= APR_SUCCESS) {
58            result : server/util_xml.c line=41 column=9
r
esult = : pass=0
=
 ap_map_http_request_error : enter=0, leave=0

ap_map_http_request_error : include/http_protocol.h line=450 column=17
a
p_map_http_request_error(status : server/util_xml.c line=37 column=18
s
tatus, HTTP_BAD_REQUEST);
59            goto : pass=0
g
oto read_error;
60        }
61
62        for : true=0, false=0
f
or (bucket : server/util_xml.c line=50 column=21
b
ucket = : pass=0
=
 APR_BRIGADE_FIRST(brigade : server/util_xml.c line=35 column=25
b
rigade);
63             bucket : server/util_xml.c line=50 column=21
b
ucket != : true=0, false=0
!
= APR_BRIGADE_SENTINEL(brigade : server/util_xml.c line=35 column=25
b
rigade);
64             bucket : server/util_xml.c line=50 column=21
b
ucket = : pass=0
=
 APR_BUCKET_NEXT(bucket : server/util_xml.c line=50 column=21
b
ucket))
65        {
66            const char *data;
67            apr_size_t len;
68
69            if : true=0, false=0
i
f (APR_BUCKET_IS_EOS(bucket : server/util_xml.c line=50 column=21
b
ucket)) {
70                seen_eos : server/util_xml.c line=36 column=9
s
een_eos = : pass=0
=
 1;
71                break : pass=0
b
reak;
72            }
73
74            if : true=0, false=0
i
f (APR_BUCKET_IS_METADATA(bucket : server/util_xml.c line=50 column=21
b
ucket)) {
75                continue : pass=0
c
ontinue;
76            }
77
78            status : server/util_xml.c line=37 column=18
s
tatus = : pass=0
=
 apr_bucket_read(bucket : server/util_xml.c line=50 column=21
b
ucket, &data : server/util_xml.c line=66 column=25
d
ata, &len : server/util_xml.c line=67 column=24
l
en, APR_BLOCK_READ : /usr/include/apr-1/apr_buckets.h line=58 column=5 APR_BLOCK_READ);
79            if : true=0, false=0
i
f (status : server/util_xml.c line=37 column=18
s
tatus != : true=0, false=0
!
= APR_SUCCESS) {
80                goto : pass=0
g
oto read_error;
81            }
82
83            total_read : server/util_xml.c line=39 column=16
t
otal_read += : pass=0
+
len : server/util_xml.c line=67 column=24
l
en;
84            if : true=0, false=0
i
f (MC/DC independently affect : true=0, false=0

limit_xml_body : server/util_xml.c line=40 column=16
lTF
imit_xml_body && : true=0, false=0
&
total_read : server/util_xml.c line=39 column=16
t
otal_read > : true=0, false=0
MC/DC independently affect : true=0, false=0
>TF
 limit_xml_body : server/util_xml.c line=40 column=16
l
imit_xml_body) {
85                ap_log_rerror : enter=0, leave=0

ap_log_rerror : include/http_log.h line=219 column=18
a
p_log_rerror(APLOG_MARK, APLOG_ERR, 0, r : server/util_xml.c line=32 column=50
r
,
86                              "XML request body is larger than the configured "
87                              "limit of %lu", (unsigned long)limit_xml_body : server/util_xml.c line=40 column=16
l
imit_xml_body);
88                result : server/util_xml.c line=41 column=9
r
esult = : pass=0
=
 HTTP_REQUEST_ENTITY_TOO_LARGE;
89                goto : pass=0
g
oto read_error;
90            }
91
92            status : server/util_xml.c line=37 column=18
s
tatus = : pass=0
=
 apr_xml_parser_feed : enter=0, leave=0

apr_xml_parser_feed : /usr/include/apr-1/apr_xml.h line=242 column=27
a
pr_xml_parser_feed(parser : server/util_xml.c line=34 column=21
p
arser, data : server/util_xml.c line=66 column=25
d
ata, len : server/util_xml.c line=67 column=24
l
en);
93            if : true=0, false=0
i
f (status : server/util_xml.c line=37 column=18
s
tatus) {
94                goto : pass=0
g
oto parser_error;
95            }
96        }
97
98        apr_brigade_cleanup : enter=0, leave=0

apr_brigade_cleanup : /usr/include/apr-1/apr_buckets.h line=679 column=27
a
pr_brigade_cleanup(brigade : server/util_xml.c line=35 column=25
b
rigade);
99    } while : true=0, false=0
w
hile (! : true=0, false=0
!
seen_eos : server/util_xml.c line=36 column=9
s
een_eos);
100
101    apr_brigade_destroy : enter=0, leave=0

apr_brigade_destroy : /usr/include/apr-1/apr_buckets.h line=666 column=27
a
pr_brigade_destroy(brigade : server/util_xml.c line=35 column=25
b
rigade);
102
103    /* tell the parser that we're done */
104    status : server/util_xml.c line=37 column=18
s
tatus = : pass=0
=
 apr_xml_parser_done : enter=0, leave=0

apr_xml_parser_done : /usr/include/apr-1/apr_xml.h line=254 column=27
a
pr_xml_parser_done(parser : server/util_xml.c line=34 column=21
p
arser, pdoc : server/util_xml.c line=32 column=67
p
doc);
105    if : true=0, false=0
i
f (status : server/util_xml.c line=37 column=18
s
tatus) {
106        /* Some parsers are stupid and return an error on blank documents. */
107        if : true=0, false=0
i
f (! : true=0, false=0
!
total_read : server/util_xml.c line=39 column=16
t
otal_read) {
108            *pdoc : server/util_xml.c line=32 column=67
p
doc = : enter=0, leave=0
=
 NULL;
109            return : pass=0
r
eturn OK;
110        }
111        ap_log_rerror : enter=0, leave=0

ap_log_rerror : include/http_log.h line=219 column=18
a
p_log_rerror(APLOG_MARK, APLOG_ERR, 0, r : server/util_xml.c line=32 column=50
r
,
112                      "XML parser error (at end). status=%d", status : server/util_xml.c line=37 column=18
s
tatus);
113        return : pass=0
r
eturn HTTP_BAD_REQUEST;
114    }
115
116#if APR_CHARSET_EBCDIC
117    apr_xml_parser_convert_doc(r->pool, *pdoc, ap_hdrs_from_ascii);
118#endif
119    return : pass=0
r
eturn OK;
120
121  parser_error:
122    (void) apr_xml_parser_geterror : enter=0, leave=0

apr_xml_parser_geterror : /usr/include/apr-1/apr_xml.h line=264 column=21
a
pr_xml_parser_geterror(parser : server/util_xml.c line=34 column=21
p
arser, errbuf : server/util_xml.c line=38 column=10
e
rrbuf, sizeof(errbuf));
123    ap_log_rerror : enter=0, leave=0

ap_log_rerror : include/http_log.h line=219 column=18
a
p_log_rerror(APLOG_MARK, APLOG_ERR, 0, r : server/util_xml.c line=32 column=50
r
,
124                  "XML Parser Error: %s", errbuf : server/util_xml.c line=38 column=10
e
rrbuf);
125
126    /* FALLTHRU */
127
128  read_error:
129    /* make sure the parser is terminated */
130    (void) apr_xml_parser_done : enter=0, leave=0

apr_xml_parser_done : /usr/include/apr-1/apr_xml.h line=254 column=27
a
pr_xml_parser_done(parser : server/util_xml.c line=34 column=21
p
arser, NULL);
131
132    apr_brigade_destroy : enter=0, leave=0

apr_brigade_destroy : /usr/include/apr-1/apr_buckets.h line=666 column=27
a
pr_brigade_destroy(brigade : server/util_xml.c line=35 column=25
b
rigade);
133
134    /* Apache will supply a default error, plus the error log above. */
135    return : pass=0
r
eturn result : server/util_xml.c line=41 column=9
r
esult;
136}
137[EOF]


Generated by expcov