removed some of the debug logging and added author details
[httpd-crcsyncproxy.git] / server / util_debug.c
blob0387c724b84cad82a9e645c3774ad01496e311b5
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
8 * http://www.apache.org/licenses/LICENSE-2.0
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.
17 #define APR_WANT_STRFUNC
18 #include "apr_want.h"
20 #include "httpd.h"
21 #include "http_config.h"
23 /* Possibly get rid of the macros we defined in httpd.h */
24 #if defined(strchr)
25 #undef strchr
26 #endif
28 #if defined (strrchr)
29 #undef strrchr
30 #endif
32 #if defined (strstr)
33 #undef strstr
34 #endif
37 #if defined(ap_strchr)
38 #undef ap_strchr
39 AP_DECLARE(char *) ap_strchr(char *s, int c);
40 #endif
42 AP_DECLARE(char *) ap_strchr(char *s, int c)
44 return strchr(s,c);
47 #if defined(ap_strchr_c)
48 #undef ap_strchr_c
49 AP_DECLARE(const char *) ap_strchr_c(const char *s, int c);
50 #endif
52 AP_DECLARE(const char *) ap_strchr_c(const char *s, int c)
54 return strchr(s,c);
57 #if defined(ap_strrchr)
58 #undef ap_strrchr
59 AP_DECLARE(char *) ap_strrchr(char *s, int c);
60 #endif
62 AP_DECLARE(char *) ap_strrchr(char *s, int c)
64 return strrchr(s,c);
67 #if defined(ap_strrchr_c)
68 #undef ap_strrchr_c
69 AP_DECLARE(const char *) ap_strrchr_c(const char *s, int c);
70 #endif
72 AP_DECLARE(const char *) ap_strrchr_c(const char *s, int c)
74 return strrchr(s,c);
77 #if defined(ap_strstr)
78 #undef ap_strstr
79 AP_DECLARE(char *) ap_strstr(char *s, const char *c);
80 #endif
82 AP_DECLARE(char *) ap_strstr(char *s, const char *c)
84 return strstr(s,c);
87 #if defined(ap_strstr_c)
88 #undef ap_strstr_c
89 AP_DECLARE(const char *) ap_strstr_c(const char *s, const char *c);
90 #endif
92 AP_DECLARE(const char *) ap_strstr_c(const char *s, const char *c)
94 return strstr(s,c);
97 #if defined(ap_get_module_config)
98 #undef ap_get_module_config
99 AP_DECLARE(void *) ap_get_module_config(const ap_conf_vector_t *cv,
100 const module *m);
101 #endif
103 AP_DECLARE(void *) ap_get_module_config(const ap_conf_vector_t *cv,
104 const module *m)
106 return ((void **)cv)[m->module_index];
110 * Generic accessors for other modules to set at their own module-specific
111 * data
112 * @param conf_vector The vector in which the modules configuration is stored.
113 * usually r->per_dir_config or s->module_config
114 * @param m The module to set the data for.
115 * @param val The module-specific data to set
116 * @fn void ap_set_module_config(ap_conf_vector_t *cv, const module *m, void *val)
118 #if defined(ap_set_module_config)
119 #undef ap_set_module_config
120 AP_DECLARE(void) ap_set_module_config(ap_conf_vector_t *cv, const module *m,
121 void *val);
122 #endif
124 AP_DECLARE(void) ap_set_module_config(ap_conf_vector_t *cv, const module *m,
125 void *val)
127 ((void **)cv)[m->module_index] = val;