From 65c3b2404560b976bfeff0db190c97d4b9487644 Mon Sep 17 00:00:00 2001 From: denis <> Date: Fri, 14 Dec 2007 22:01:14 +0000 Subject: add support for more stats: 1. stats for added and removed torrents 2. stats for start and stopped events from peers this should help to detect DoS attacks and is useful for profiling --- ot_http.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'ot_http.c') diff --git a/ot_http.c b/ot_http.c index faf1aae..a377e84 100644 --- a/ot_http.c +++ b/ot_http.c @@ -251,6 +251,10 @@ static ssize_t http_handle_stats( const int64 client_socket, char *data, char *d mode = TASK_STATS_TPB; else if( !byte_diff(data,4,"herr")) mode = TASK_STATS_HTTPERRORS; + else if( !byte_diff(data,9,"startstop")) + mode = TASK_STATS_STARTSTOP; + else if( !byte_diff(data,10,"toraddrem")) + mode = TASK_STATS_TORADDREM; else HTTPERROR_400_PARAM; break; -- cgit v1.2.3