]> granicus.if.org Git - apache/commitdiff
Follow up to r1739201.
authorYann Ylavic <ylavic@apache.org>
Fri, 28 Oct 2016 10:56:03 +0000 (10:56 +0000)
committerYann Ylavic <ylavic@apache.org>
Fri, 28 Oct 2016 10:56:03 +0000 (10:56 +0000)
These APR_TIMEUP special cases are now handled by ap_map_http_request_error().

git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1766998 13f79535-47bb-0310-9956-ffa450edef68

modules/dav/main/mod_dav.c
modules/generators/mod_cgi.c
modules/generators/mod_cgid.c

index 1a1730e53e5f45478851e1c095e1d8b4e1de0abc..6808e2cfea2ebe1fc5c810e42cf522af402e09a7 100644 (file)
@@ -1039,17 +1039,10 @@ static int dav_method_put(request_rec *r)
             if (rc != APR_SUCCESS) {
                 int http_err;
                 char *msg = ap_escape_html(r->pool, r->uri);
-                if (APR_STATUS_IS_TIMEUP(rc)) {
-                    http_err = HTTP_REQUEST_TIME_OUT;
-                    msg = apr_psprintf(r->pool, "Timeout reading the body "
-                                       "(URI: %s)", msg);
-                }
-                else {
-                    http_err = ap_map_http_request_error(rc, HTTP_BAD_REQUEST);
-                    msg = apr_psprintf(r->pool,
-                            "An error occurred while reading"
-                                    " the request body (URI: %s)", msg);
-                }
+                http_err = ap_map_http_request_error(rc, HTTP_BAD_REQUEST);
+                msg = apr_psprintf(r->pool, "An error occurred while reading "
+                                            "the request body (URI: %s)",
+                                            msg);
                 err = dav_new_error(r->pool, http_err, 0, rc, msg);
                 break;
             }
index 000f06e5bd52a960560d358bddb08e27864db0d7..8c4a2c63600b6cc0b10fea1333dc2d7d303c49fc 100644 (file)
@@ -853,11 +853,6 @@ static int cgi_handler(request_rec *r)
                             APR_BLOCK_READ, HUGE_STRING_LEN);
 
         if (rv != APR_SUCCESS) {
-            if (APR_STATUS_IS_TIMEUP(rv)) {
-                ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(01224)
-                              "Timeout during reading request entity data");
-                return HTTP_REQUEST_TIME_OUT;
-            }
             ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(01225)
                           "Error reading request entity data");
             return ap_map_http_request_error(rv, HTTP_BAD_REQUEST);
index 1148467b46d9a671f8ea57c4b637d6efbff719ed..b827ed6ac450f19cedab0d64cbd8ece825415888 100644 (file)
@@ -1534,11 +1534,6 @@ static int cgid_handler(request_rec *r)
                             APR_BLOCK_READ, HUGE_STRING_LEN);
 
         if (rv != APR_SUCCESS) {
-            if (APR_STATUS_IS_TIMEUP(rv)) {
-                ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(01269)
-                              "Timeout during reading request entity data");
-                return HTTP_REQUEST_TIME_OUT;
-            }
             ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r, APLOGNO(01270)
                           "Error reading request entity data");
             return ap_map_http_request_error(rv, HTTP_BAD_REQUEST);