summaryrefslogtreecommitdiff
path: root/methods
diff options
context:
space:
mode:
authorDavid Kalnischkies <david@kalnischkies.de>2018-05-26 21:28:55 +0200
committerDavid Kalnischkies <david@kalnischkies.de>2018-05-28 17:59:38 +0200
commit2fc09a90e7e62a4c3e4a67506bf90fcf4c6ccfaf (patch)
tree81bba2a4f1ddb2dd79a81c3bfd874c31748e51f6 /methods
parent79b61ae7673eb6213493e2cb202f0d70c390932d (diff)
Remove unused time-tracking from http method
The Stats method isn't called anywhere, was partly commented out before, but we keep updating the time for it – lets avoid this pointless busywork. Gbp-Dch: Ignore
Diffstat (limited to 'methods')
-rw-r--r--methods/http.cc17
-rw-r--r--methods/http.h3
2 files changed, 0 insertions, 20 deletions
diff --git a/methods/http.cc b/methods/http.cc
index 3862497a8..1933d9d00 100644
--- a/methods/http.cc
+++ b/methods/http.cc
@@ -134,8 +134,6 @@ bool CircleBuf::Read(std::unique_ptr<MethodFd> const &Fd)
return false;
}
- if (InP == 0)
- gettimeofday(&Start,0);
InP += Res;
}
}
@@ -267,21 +265,6 @@ bool CircleBuf::Write(string &Data)
return true;
}
/*}}}*/
-// CircleBuf::Stats - Print out stats information /*{{{*/
-// ---------------------------------------------------------------------
-/* */
-void CircleBuf::Stats()
-{
- if (InP == 0)
- return;
-
- struct timeval Stop;
- gettimeofday(&Stop,0);
-/* float Diff = Stop.tv_sec - Start.tv_sec +
- (float)(Stop.tv_usec - Start.tv_usec)/1000000;
- clog << "Got " << InP << " in " << Diff << " at " << InP/Diff << endl;*/
-}
- /*}}}*/
CircleBuf::~CircleBuf() /*{{{*/
{
delete [] Buf;
diff --git a/methods/http.h b/methods/http.h
index d511196e3..ae6cedc13 100644
--- a/methods/http.h
+++ b/methods/http.h
@@ -36,7 +36,6 @@ class CircleBuf
std::string OutQueue;
unsigned long long StrPos;
unsigned long long MaxGet;
- struct timeval Start;
static unsigned long long BwReadLimit;
static unsigned long long BwTickReadData;
@@ -85,8 +84,6 @@ class CircleBuf
bool WriteSpace() const {return InP - OutP > 0;};
void Reset();
- // Dump everything
- void Stats();
CircleBuf(HttpMethod const * const Owner, unsigned long long Size);
~CircleBuf();