]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Fixed a dangerous lie in the dereferenceIdle() description (#163)
authorAlex Rousskov <rousskov@measurement-factory.com>
Tue, 27 Feb 2018 00:25:16 +0000 (17:25 -0700)
committerAmos Jeffries <yadij@users.noreply.github.com>
Tue, 27 Feb 2018 00:25:16 +0000 (13:25 +1300)
Also moved private Controller method descriptions to .cc per convention.

src/store/Controller.cc
src/store/Controller.h

index 0affe2edb743fe71a7cf59b9bd7f93199f703fe2..bebc65e05cec987dcf70a29b370bfbf5044fef56 100644 (file)
@@ -233,6 +233,7 @@ Store::Controller::callback()
     return result;
 }
 
+/// update reference counters of the recently touched entry
 void
 Store::Controller::referenceBusy(StoreEntry &e)
 {
@@ -256,6 +257,8 @@ Store::Controller::referenceBusy(StoreEntry &e)
     }
 }
 
+/// dereference()s an idle entry
+/// \returns false if and only if the entry should be deleted
 bool
 Store::Controller::dereferenceIdle(StoreEntry &e, bool wantsLocalMemory)
 {
index 1bce65e8f748cdeb8fa2321e9ac7b15239466e26..3a5290059c4daf3b28de00b06fa84330c0843231 100644 (file)
@@ -136,9 +136,7 @@ public:
 private:
     bool memoryCacheHasSpaceFor(const int pagesRequired) const;
 
-    /// update reference counters of the recently touched entry
     void referenceBusy(StoreEntry &e);
-    /// dereference() an idle entry and return true if the entry should be deleted
     bool dereferenceIdle(StoreEntry &, bool wantsLocalMemory);
 
     void allowSharing(StoreEntry &, const cache_key *);