]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Bug 5129 pt1: remove Lock use from HttpRequestMethod (#825)
authorAmos Jeffries <yadij@users.noreply.github.com>
Mon, 17 May 2021 08:10:33 +0000 (08:10 +0000)
committerSquid Anubis <squid-anubis@squid-cache.org>
Mon, 17 May 2021 09:48:13 +0000 (09:48 +0000)
Removes the need for a custom assignment operator with a questionable
implementation, addressing compiler and static analysis warnings.

src/http/RequestMethod.h
src/http/forward.h

index f59c3f12432f2a9f26b6a9583e5a66e5d29f399a..9169260c8475d512e7112709a6c1a302758579dc 100644 (file)
@@ -23,7 +23,7 @@ class SquidConfig;
  * It has a runtime extension facility to allow it to
  * efficiently support new methods
  */
-class HttpRequestMethod : public RefCountable
+class HttpRequestMethod
 {
 public:
     HttpRequestMethod() : theMethod(Http::METHOD_NONE), theImage() {}
@@ -32,12 +32,6 @@ public:
 
     void HttpRequestMethodXXX(char const *); // deprecated old c-string to SBuf converter.
 
-    HttpRequestMethod & operator = (const HttpRequestMethod& aMethod) {
-        theMethod = aMethod.theMethod;
-        theImage = aMethod.theImage;
-        return *this;
-    }
-
     HttpRequestMethod & operator = (Http::MethodType const aMethod) {
         theMethod = aMethod;
         theImage.clear();
index f362a71c13b34d2115083e02afef341c7f89676f..c5f695d0c736ef8dbf1199912017ac9a60fa0169 100644 (file)
@@ -38,7 +38,6 @@ typedef enum {
 class HttpHdrSc;
 
 class HttpRequestMethod;
-typedef RefCount<HttpRequestMethod> HttpRequestMethodPointer;
 
 class HttpRequest;
 typedef RefCount<HttpRequest> HttpRequestPointer;