]> granicus.if.org Git - apache/commitdiff
Code clean up (remove useless memory allocation)
authorStefan Fritsch <sf@apache.org>
Sun, 15 Jul 2012 21:19:54 +0000 (21:19 +0000)
committerStefan Fritsch <sf@apache.org>
Sun, 15 Jul 2012 21:19:54 +0000 (21:19 +0000)
Submitted by: Christophe JAILLET <christophe jaillet wanadoo fr>
PR: 52648

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

modules/arch/win32/mod_isapi.c
modules/generators/mod_asis.c
modules/generators/mod_cgi.c
modules/generators/mod_cgid.c
modules/http/http_request.c

index d77ff6882f24efcce80851804b1fec5f8cca9a05..f6cb99a260fa21365d1f7393c1ded4fc0c5cb0cf 100644 (file)
@@ -894,7 +894,7 @@ static int APR_THREAD_FUNC regfnServerSupportFunction(isapi_cid    *cid,
         }
 
         /* Reset the method to GET */
-        r->method = apr_pstrdup(r->pool, "GET");
+        r->method = "GET";
         r->method_number = M_GET;
 
         /* Don't let anyone think there's still data */
index 1fc14389a57ca3f888311a3fe57b1bdbebd27847..c947e30360f4c13276f98d3db43099045166126f 100644 (file)
@@ -70,7 +70,7 @@ static int asis_handler(request_rec *r)
         /* This redirect needs to be a GET no matter what the original
          * method was.
          */
-        r->method = apr_pstrdup(r->pool, "GET");
+        r->method = "GET";
         r->method_number = M_GET;
 
         ap_internal_redirect_handler(location, r);
index 385bb36495fbdb8d78c1874e0c9b4d754438ec58..a609654524f75bdff0a34833cd8f1ce2ae2231cb 100644 (file)
@@ -993,7 +993,7 @@ static int cgi_handler(request_rec *r)
             /* This redirect needs to be a GET no matter what the original
              * method was.
              */
-            r->method = apr_pstrdup(r->pool, "GET");
+            r->method = "GET";
             r->method_number = M_GET;
 
             /* We already read the message body (if any), so don't allow
index 5cf7cf5895b6ac3e6a06162386ef56f094d44593..56d35243308ab711367db4c21801c95b2be76c66 100644 (file)
@@ -1594,7 +1594,7 @@ static int cgid_handler(request_rec *r)
             /* This redirect needs to be a GET no matter what the original
              * method was.
              */
-            r->method = apr_pstrdup(r->pool, "GET");
+            r->method = "GET";
             r->method_number = M_GET;
 
             /* We already read the message body (if any), so don't allow
index ce16de922b3be1a627dc2a52f03e7f7c4181a5ca..21c6debd606554a1f4b8fd08d76e0aa7ef6f6c21 100644 (file)
@@ -197,7 +197,7 @@ AP_DECLARE(void) ap_die(int type, request_rec *r)
                                              "error-notes")) != NULL) {
                 apr_table_setn(r->subprocess_env, "ERROR_NOTES", error_notes);
             }
-            r->method = apr_pstrdup(r->pool, "GET");
+            r->method = "GET";
             r->method_number = M_GET;
             ap_internal_redirect(custom_response, r);
             return;