We actually compare the canonical root to this root, (but we don't * waste time checking the case), since every use of this function in * httpd-2.1 tests if the path is 'proper', meaning we've already passed * it through apr_filepath_merge, or we haven't. */
| 227 | * it through apr_filepath_merge, or we haven't. |
| 228 | */ |
| 229 | AP_DECLARE(int) ap_os_is_path_absolute(apr_pool_t *p, const char *dir) |
| 230 | { |
| 231 | const char *newpath; |
| 232 | const char *ourdir = dir; |
| 233 | if (apr_filepath_root(&newpath, &dir, 0, p) != APR_SUCCESS |
| 234 | || strncmp(newpath, ourdir, strlen(newpath)) != 0) { |
| 235 | return 0; |
| 236 | } |
| 237 | return 1; |
| 238 | } |
| 239 | |
| 240 | AP_DECLARE(int) ap_is_matchexp(const char *str) |
| 241 | { |
no outgoing calls
no test coverage detected