From 2090fa874841512f229019b52a04aede28c3536a Mon Sep 17 00:00:00 2001 From: Doug MacEachern Date: Sun, 19 Aug 2001 16:01:05 +0000 Subject: adjust to apr_uri_ rename git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@90361 13f79535-47bb-0310-9956-ffa450edef68 --- modules/aaa/mod_auth_digest.c | 10 +++++----- modules/dav/main/util.c | 10 +++++----- modules/loggers/mod_log_config.c | 2 +- modules/mappers/mod_alias.c | 4 ++-- modules/test/mod_test_util_uri.c | 4 ++-- 5 files changed, 15 insertions(+), 15 deletions(-) (limited to 'modules') diff --git a/modules/aaa/mod_auth_digest.c b/modules/aaa/mod_auth_digest.c index e7ddc7e15d..5e55b89bed 100644 --- a/modules/aaa/mod_auth_digest.c +++ b/modules/aaa/mod_auth_digest.c @@ -236,7 +236,7 @@ typedef struct digest_header_struct { apr_time_t nonce_time; enum hdr_sts auth_hdr_sts; const char *raw_request_uri; - apr_uri_components *psd_request_uri; + apr_uri_t *psd_request_uri; int needed_auth; client_entry *client; } digest_header_rec; @@ -1514,8 +1514,8 @@ static const char *new_digest(const request_rec *r, } -static void copy_uri_components(apr_uri_components *dst, - apr_uri_components *src, request_rec *r) { +static void copy_uri_components(apr_uri_t *dst, + apr_uri_t *src, request_rec *r) { if (src->scheme && src->scheme[0] != '\0') dst->scheme = src->scheme; else @@ -1624,10 +1624,10 @@ static int authenticate_digest_user(request_rec *r) /* Hmm, the simple match didn't work (probably a proxy modified the * request-uri), so lets do a more sophisticated match */ - apr_uri_components r_uri, d_uri; + apr_uri_t r_uri, d_uri; copy_uri_components(&r_uri, resp->psd_request_uri, r); - if (apr_uri_parse_components(r->pool, resp->uri, &d_uri) != APR_SUCCESS) { + if (apr_uri_parse(r->pool, resp->uri, &d_uri) != APR_SUCCESS) { ap_log_rerror(APLOG_MARK, APLOG_NOERRNO|APLOG_ERR, 0, r, "Digest: invalid uri <%s> in Authorization header", resp->uri); diff --git a/modules/dav/main/util.c b/modules/dav/main/util.c index e5419a41e8..01d345f253 100644 --- a/modules/dav/main/util.c +++ b/modules/dav/main/util.c @@ -189,12 +189,12 @@ dav_lookup_result dav_lookup_uri(const char *uri, request_rec * r, dav_lookup_result result = { 0 }; const char *scheme; apr_port_t port; - apr_uri_components comp; + apr_uri_t comp; char *new_file; const char *domain; /* first thing to do is parse the URI into various components */ - if (apr_uri_parse_components(r->pool, uri, &comp) != APR_SUCCESS) { + if (apr_uri_parse(r->pool, uri, &comp) != APR_SUCCESS) { result.err.status = HTTP_BAD_REQUEST; result.err.desc = "Invalid syntax in Destination URI."; return result; @@ -288,7 +288,7 @@ dav_lookup_result dav_lookup_uri(const char *uri, request_rec * r, the current request. Therefore, we can use ap_sub_req_lookup_uri() */ /* reconstruct a URI as just the path */ - new_file = apr_uri_unparse_components(r->pool, &comp, APR_URI_UNP_OMITSITEPART); + new_file = apr_uri_unparse(r->pool, &comp, APR_URI_UNP_OMITSITEPART); /* * Lookup the URI and return the sub-request. Note that we use the @@ -542,7 +542,7 @@ static dav_error * dav_process_if_header(request_rec *r, dav_if_header **p_ih) const char *uri = NULL; /* scope of current production; NULL=no-tag */ size_t uri_len = 0; dav_if_header *ih = NULL; - apr_uri_components parsed_uri; + apr_uri_t parsed_uri; const dav_hooks_locks *locks_hooks = DAV_GET_HOOKS_LOCKS(r); enum {no_tagged, tagged, unknown} list_type = unknown; int condition; @@ -566,7 +566,7 @@ static dav_error * dav_process_if_header(request_rec *r, dav_if_header **p_ih) /* 2518 specifies this must be an absolute URI; just take the * relative part for later comparison against r->uri */ - if (apr_uri_parse_components(r->pool, uri, &parsed_uri) != APR_SUCCESS) { + if (apr_uri_parse(r->pool, uri, &parsed_uri) != APR_SUCCESS) { return dav_new_error(r->pool, HTTP_BAD_REQUEST, DAV_ERR_IF_TAGGED, "Invalid URI in tagged If-header."); diff --git a/modules/loggers/mod_log_config.c b/modules/loggers/mod_log_config.c index 3e5ae5c144..b32ab105d7 100644 --- a/modules/loggers/mod_log_config.c +++ b/modules/loggers/mod_log_config.c @@ -344,7 +344,7 @@ static const char *log_request_line(request_rec *r, char *a) * (note also that r->the_request contains the unmodified request) */ return (r->parsed_uri.password) ? apr_pstrcat(r->pool, r->method, " ", - apr_uri_unparse_components(r->pool, &r->parsed_uri, 0), + apr_uri_unparse(r->pool, &r->parsed_uri, 0), r->assbackwards ? NULL : " ", r->protocol, NULL) : r->the_request; } diff --git a/modules/mappers/mod_alias.c b/modules/mappers/mod_alias.c index f37228571f..31aa90e456 100644 --- a/modules/mappers/mod_alias.c +++ b/modules/mappers/mod_alias.c @@ -335,8 +335,8 @@ static char *try_alias_list(request_rec *r, apr_array_header_t *aliases, int doe found = ap_pregsub(r->pool, p->real, r->uri, p->regexp->re_nsub + 1, regm); if (found && doesc) { - apr_uri_components uri; - apr_uri_parse_components(r->pool, found, &uri); + apr_uri_t uri; + apr_uri_parse(r->pool, found, &uri); found = ap_escape_uri(r->pool, uri.path); if (uri.query) { found = apr_pstrcat(r->pool, found, "?", uri.query, NULL); diff --git a/modules/test/mod_test_util_uri.c b/modules/test/mod_test_util_uri.c index 1ba90c8fce..45ca811ae9 100644 --- a/modules/test/mod_test_util_uri.c +++ b/modules/test/mod_test_util_uri.c @@ -142,7 +142,7 @@ static unsigned iterate_pieces(request_rec *r, const test_uri_t *pieces, int row apr_pool_t *sub; char *input_uri; char *strp; - apr_uri_components result; + apr_uri_t result; unsigned expect; int status; unsigned failures; @@ -208,7 +208,7 @@ static unsigned iterate_pieces(request_rec *r, const test_uri_t *pieces, int row *strp = 0; apr_pool_sub_make(&sub, r->pool, NULL); - status = apr_uri_parse_components(sub, input_uri, &result); + status = apr_uri_parse(sub, input_uri, &result); if (status == APR_SUCCESS) { #define CHECK(f) \ if ((expect & T_##f) \ -- cgit v1.2.3