mirror of
git://erdgeist.org/opentracker
synced 2025-03-31 02:22:55 +08:00
Enable revision watching from the internet
This commit is contained in:
parent
eadb0b8436
commit
57387588ed
@ -253,10 +253,12 @@ static ssize_t http_handle_stats( const int64 client_socket, char *data, char *d
|
|||||||
mode = TASK_STATS_TPB;
|
mode = TASK_STATS_TPB;
|
||||||
else if( !byte_diff(data,4,"herr"))
|
else if( !byte_diff(data,4,"herr"))
|
||||||
mode = TASK_STATS_HTTPERRORS;
|
mode = TASK_STATS_HTTPERRORS;
|
||||||
else if( !byte_diff(data,9,"startstop"))
|
else if( !byte_diff(data,4,"startstop"))
|
||||||
mode = TASK_STATS_STARTSTOP;
|
mode = TASK_STATS_STARTSTOP;
|
||||||
else if( !byte_diff(data,10,"toraddrem"))
|
else if( !byte_diff(data,4,"toraddrem"))
|
||||||
mode = TASK_STATS_TORADDREM;
|
mode = TASK_STATS_TORADDREM;
|
||||||
|
else if( !byte_diff(data,4,"vers"))
|
||||||
|
mode = TASK_STATS_VERSION;
|
||||||
else
|
else
|
||||||
HTTPERROR_400_PARAM;
|
HTTPERROR_400_PARAM;
|
||||||
break;
|
break;
|
||||||
|
@ -28,6 +28,7 @@ typedef enum {
|
|||||||
TASK_STATS_TORRENTS = 0x0009,
|
TASK_STATS_TORRENTS = 0x0009,
|
||||||
TASK_STATS_STARTSTOP = 0x000a,
|
TASK_STATS_STARTSTOP = 0x000a,
|
||||||
TASK_STATS_TORADDREM = 0x000b,
|
TASK_STATS_TORADDREM = 0x000b,
|
||||||
|
TASK_STATS_VERSION = 0x000c,
|
||||||
|
|
||||||
TASK_STATS_SLASH24S = 0x0100,
|
TASK_STATS_SLASH24S = 0x0100,
|
||||||
|
|
||||||
|
@ -375,6 +375,8 @@ size_t return_stats_for_tracker( char *reply, int mode, int format ) {
|
|||||||
return stats_fullscrapes_mrtg( reply );
|
return stats_fullscrapes_mrtg( reply );
|
||||||
case TASK_STATS_HTTPERRORS:
|
case TASK_STATS_HTTPERRORS:
|
||||||
return stats_httperrors_txt( reply );
|
return stats_httperrors_txt( reply );
|
||||||
|
case TASK_STATS_VERSION:
|
||||||
|
return stats_return_tracker_version( reply );
|
||||||
default:
|
default:
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user