Author: ivan Date: Sat Apr 22 17:33:57 2023 New Revision: 1909355 URL: http://svn.apache.org/viewvc?rev=1909355&view=rev Log: On the '1.3.x-r1901937' branch: Merge changes from the 1.3.x branch.
Modified: serf/branches/1.3.x-r1901937/ (props changed) serf/branches/1.3.x-r1901937/test/serf_bwtp.c serf/branches/1.3.x-r1901937/test/serf_get.c serf/branches/1.3.x-r1901937/test/serf_spider.c serf/branches/1.3.x-r1901937/test/test_buckets.c serf/branches/1.3.x-r1901937/test/test_context.c Propchange: serf/branches/1.3.x-r1901937/ ------------------------------------------------------------------------------ Merged /serf/trunk:r1699725,1699807 Merged /serf/branches/1.3.x:r1909328-1909354 Modified: serf/branches/1.3.x-r1901937/test/serf_bwtp.c URL: http://svn.apache.org/viewvc/serf/branches/1.3.x-r1901937/test/serf_bwtp.c?rev=1909355&r1=1909354&r2=1909355&view=diff ============================================================================== --- serf/branches/1.3.x-r1901937/test/serf_bwtp.c (original) +++ serf/branches/1.3.x-r1901937/test/serf_bwtp.c Sat Apr 22 17:33:57 2023 @@ -155,7 +155,6 @@ static apr_status_t setup_request(serf_r { handler_baton_t *ctx = setup_baton; serf_bucket_t *hdrs_bkt; - serf_bucket_t *body_bkt; if (ctx->req_body_path) { apr_file_t *file; @@ -168,12 +167,13 @@ static apr_status_t setup_request(serf_r printf("Error opening file (%s)\n", ctx->req_body_path); return status; } - +/* body_bkt = serf_bucket_file_create(file, serf_request_get_alloc(request)); +*/ } else { - body_bkt = NULL; +/* body_bkt = NULL;*/ } /* @@ -371,18 +371,17 @@ static apr_status_t handle_bwtp_upgrade( if (APR_STATUS_IS_EOF(status)) { int i; serf_connection_t *conn; - serf_request_t *new_req; conn = serf_request_get_conn(request); serf_connection_set_async_responses(conn, accept_bwtp, ctx->acceptor_baton, handle_bwtp, NULL); - new_req = serf_connection_request_create(conn, setup_channel, ctx); + serf_connection_request_create(conn, setup_channel, ctx); for (i = 0; i < ctx->acceptor_baton->count; i++) { - new_req = serf_connection_request_create(conn, - setup_request, - ctx); + serf_connection_request_create(conn, + setup_request, + ctx); } return APR_EOF; @@ -445,11 +444,9 @@ static apr_status_t handle_response(serf apr_atomic_dec32(&ctx->requests_outstanding); if (!ctx->requests_outstanding) { serf_connection_t *conn; - serf_request_t *new_req; conn = serf_request_get_conn(request); - new_req = - serf_connection_request_create(conn, setup_close, ctx); + serf_connection_request_create(conn, setup_close, ctx); } return APR_EOF; } @@ -482,7 +479,6 @@ int main(int argc, const char **argv) apr_sockaddr_t *address; serf_context_t *context; serf_connection_t *connection; - serf_request_t *request; app_baton_t app_ctx; handler_baton_t handler_ctx; apr_uri_t url; @@ -607,8 +603,8 @@ int main(int argc, const char **argv) handler_ctx.acceptor_baton = &app_ctx; handler_ctx.handler = handle_response; - request = serf_connection_request_create(connection, setup_bwtp_upgrade, - &handler_ctx); + serf_connection_request_create(connection, setup_bwtp_upgrade, + &handler_ctx); for (i = 0; i < app_ctx.count; i++) { apr_atomic_inc32(&handler_ctx.requests_outstanding); Modified: serf/branches/1.3.x-r1901937/test/serf_get.c URL: http://svn.apache.org/viewvc/serf/branches/1.3.x-r1901937/test/serf_get.c?rev=1909355&r1=1909354&r2=1909355&view=diff ============================================================================== --- serf/branches/1.3.x-r1901937/test/serf_get.c (original) +++ serf/branches/1.3.x-r1901937/test/serf_get.c Sat Apr 22 17:33:57 2023 @@ -420,7 +420,6 @@ int main(int argc, const char **argv) serf_bucket_alloc_t *bkt_alloc; serf_context_t *context; serf_connection_t *connection; - serf_request_t *request; app_baton_t app_ctx; handler_baton_t handler_ctx; serf_bucket_t *req_hdrs = NULL; @@ -652,8 +651,9 @@ int main(int argc, const char **argv) serf_connection_set_max_outstanding_requests(connection, inflight); for (i = 0; i < count; i++) { - request = serf_connection_request_create(connection, setup_request, - &handler_ctx); + /* We don't need the returned request here. */ + serf_connection_request_create(connection, setup_request, + &handler_ctx); } while (1) { Modified: serf/branches/1.3.x-r1901937/test/serf_spider.c URL: http://svn.apache.org/viewvc/serf/branches/1.3.x-r1901937/test/serf_spider.c?rev=1909355&r1=1909354&r2=1909355&view=diff ============================================================================== --- serf/branches/1.3.x-r1901937/test/serf_spider.c (original) +++ serf/branches/1.3.x-r1901937/test/serf_spider.c Sat Apr 22 17:33:57 2023 @@ -329,10 +329,6 @@ static apr_status_t setup_request(serf_r } if (ctx->app_ctx->using_ssl) { - serf_bucket_alloc_t *req_alloc; - - req_alloc = serf_request_get_alloc(request); - if (ctx->app_ctx->ssl_ctx == NULL) { *req_bkt = serf_bucket_ssl_encrypt_create(*req_bkt, NULL, ctx->app_ctx->bkt_alloc); @@ -632,8 +628,7 @@ int main(int argc, const char **argv) app_baton_t app_ctx; handler_baton_t *handler_ctx; apr_uri_t url; - const char *raw_url, *method; - int count; + const char *raw_url; apr_getopt_t *opt; char opt_c; char *authn = NULL; @@ -652,11 +647,6 @@ int main(int argc, const char **argv) apr_atomic_init(pool); /* serf_initialize(); */ - /* Default to one round of fetching. */ - count = 1; - /* Default to GET. */ - method = "GET"; - apr_getopt_init(&opt, pool, argc, argv); while ((status = apr_getopt(opt, "a:hv", &opt_c, &opt_arg)) == Modified: serf/branches/1.3.x-r1901937/test/test_buckets.c URL: http://svn.apache.org/viewvc/serf/branches/1.3.x-r1901937/test/test_buckets.c?rev=1909355&r1=1909354&r2=1909355&view=diff ============================================================================== --- serf/branches/1.3.x-r1901937/test/test_buckets.c (original) +++ serf/branches/1.3.x-r1901937/test/test_buckets.c Sat Apr 22 17:33:57 2023 @@ -1178,12 +1178,14 @@ static void test_random_eagain_in_respon !SERF_BUCKET_READ_ERROR(status)); errmsg = apr_psprintf(iter_pool, "Read more data than expected, EAGAIN" - " inserted at pos: %d, remainder: \"%s\"", + " inserted at pos: %" APR_SIZE_T_FMT + ", remainder: \"%s\"", cut, fullmsg + cut); CuAssert(tc, errmsg, strlen(ptr) >= len); errmsg = apr_psprintf(iter_pool, "Read data is not equal to expected, EAGAIN" - " inserted at pos: %d, remainder: \"%s\"", + " inserted at pos: %" APR_SIZE_T_FMT + ", remainder: \"%s\"", cut, fullmsg + cut); CuAssertStrnEquals_Msg(tc, errmsg, ptr, len, data); Modified: serf/branches/1.3.x-r1901937/test/test_context.c URL: http://svn.apache.org/viewvc/serf/branches/1.3.x-r1901937/test/test_context.c?rev=1909355&r1=1909354&r2=1909355&view=diff ============================================================================== --- serf/branches/1.3.x-r1901937/test/test_context.c (original) +++ serf/branches/1.3.x-r1901937/test/test_context.c Sat Apr 22 17:33:57 2023 @@ -651,7 +651,6 @@ static void test_connection_userinfo_in_ handler_baton_t handler_ctx[2]; const int num_requests = sizeof(handler_ctx)/sizeof(handler_ctx[0]); int i; - progress_baton_t *pb; test_server_message_t message_list[] = { {CHUNKED_REQUEST(1, "1")},