summaryrefslogtreecommitdiff
path: root/ot_stats.c
diff options
context:
space:
mode:
Diffstat (limited to 'ot_stats.c')
-rw-r--r--ot_stats.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ot_stats.c b/ot_stats.c
index 6116c41..a3cce63 100644
--- a/ot_stats.c
+++ b/ot_stats.c
@@ -452,9 +452,9 @@ static size_t stats_return_everything( char * reply ) {
452 452
453 iterate_all_torrents( torrent_statter, (uintptr_t)&stats ); 453 iterate_all_torrents( torrent_statter, (uintptr_t)&stats );
454 454
455 r += sprintf( r, "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" ); 455 r += sprintf( r, "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" );
456 r += sprintf( r, "<version>\n" ); r += stats_return_tracker_version( r ); r += sprintf( r, "</version>\n" );
457 r += sprintf( r, "<stats>\n" ); 456 r += sprintf( r, "<stats>\n" );
457 r += sprintf( r, " <version>\n" ); r += stats_return_tracker_version( r ); r += sprintf( r, " </version>\n" );
458 r += sprintf( r, " <uptime>%llu</uptime>\n", (unsigned long long)(time( NULL ) - ot_start_time) ); 458 r += sprintf( r, " <uptime>%llu</uptime>\n", (unsigned long long)(time( NULL ) - ot_start_time) );
459 r += sprintf( r, " <torrents>\n" ); 459 r += sprintf( r, " <torrents>\n" );
460 r += sprintf( r, " <count_mutex>%zd</count_mutex>\n", mutex_get_torrent_count() ); 460 r += sprintf( r, " <count_mutex>%zd</count_mutex>\n", mutex_get_torrent_count() );
@@ -464,7 +464,7 @@ static size_t stats_return_everything( char * reply ) {
464 r += sprintf( r, " <seeds>\n <count>%llu</count>\n </seeds>\n", stats.seed_count ); 464 r += sprintf( r, " <seeds>\n <count>%llu</count>\n </seeds>\n", stats.seed_count );
465 r += sprintf( r, " <connections>\n" ); 465 r += sprintf( r, " <connections>\n" );
466 r += sprintf( r, " <tcp>\n <accept>%llu</accept>\n <announce>%llu</announce>\n <scrape>%llu</scrape>\n </tcp>\n", ot_overall_tcp_connections, ot_overall_tcp_successfulannounces, ot_overall_udp_successfulscrapes ); 466 r += sprintf( r, " <tcp>\n <accept>%llu</accept>\n <announce>%llu</announce>\n <scrape>%llu</scrape>\n </tcp>\n", ot_overall_tcp_connections, ot_overall_tcp_successfulannounces, ot_overall_udp_successfulscrapes );
467 r += sprintf( r, " <udp>\n <overall>%llu</overall>\n <connect>%llu</connect>\n <announce>%llu</announce>\n <scrape>%llu</scrape>\n </tcp>\n", ot_overall_udp_connections, ot_overall_udp_connects, ot_overall_udp_successfulannounces, ot_overall_udp_successfulscrapes ); 467 r += sprintf( r, " <udp>\n <overall>%llu</overall>\n <connect>%llu</connect>\n <announce>%llu</announce>\n <scrape>%llu</scrape>\n </udp>\n", ot_overall_udp_connections, ot_overall_udp_connects, ot_overall_udp_successfulannounces, ot_overall_udp_successfulscrapes );
468 r += sprintf( r, " <livesync>\n <count>%llu</count>\n </livesync>\n", ot_overall_sync_count ); 468 r += sprintf( r, " <livesync>\n <count>%llu</count>\n </livesync>\n", ot_overall_sync_count );
469 r += sprintf( r, " </connections>\n" ); 469 r += sprintf( r, " </connections>\n" );
470 r += sprintf( r, " <debug>\n" ); 470 r += sprintf( r, " <debug>\n" );