Bug 1245868 - repalce pass by value with pass by pointer in IsHeadRequest. r?jst draft
authorBogdan Postelnicu <bogdan.postelnicu@softvision.ro>
Wed, 17 Feb 2016 10:17:20 +0200
changeset 331439 8d714ee220fd68840d09d3c4efff9d80b9304666
parent 331237 6ea654cad929c9bedd8a4161a182b6189fbeae6a
child 514389 a430d1e4586d9838003767ab734594365235a412
push id10992
push userBogdan.Postelnicu@softvision.ro
push dateWed, 17 Feb 2016 08:53:09 +0000
reviewersjst
bugs1245868
milestone47.0a1
Bug 1245868 - repalce pass by value with pass by pointer in IsHeadRequest. r?jst MozReview-Commit-ID: 5eZ2XLmIjkk
dom/cache/Manager.cpp
--- a/dom/cache/Manager.cpp
+++ b/dom/cache/Manager.cpp
@@ -142,22 +142,22 @@ public:
 
     aResolver->Resolve(rv);
   }
 
 private:
   nsTArray<nsID> mDeletedBodyIdList;
 };
 
-bool IsHeadRequest(CacheRequest aRequest, CacheQueryParams aParams)
+bool IsHeadRequest(const CacheRequest& aRequest, const CacheQueryParams& aParams)
 {
   return !aParams.ignoreMethod() && aRequest.method().LowerCaseEqualsLiteral("head");
 }
 
-bool IsHeadRequest(CacheRequestOrVoid aRequest, CacheQueryParams aParams)
+bool IsHeadRequest(const CacheRequestOrVoid& aRequest, const CacheQueryParams& aParams)
 {
   if (aRequest.type() == CacheRequestOrVoid::TCacheRequest) {
     return !aParams.ignoreMethod() &&
            aRequest.get_CacheRequest().method().LowerCaseEqualsLiteral("head");
   }
   return false;
 }