diff options
-rw-r--r-- | ot_stats.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -306,14 +306,14 @@ void stats_issue_event( ot_status_event event, int is_tcp, size_t event_data ) { | |||
306 | break; | 306 | break; |
307 | case EVENT_FULLSCRAPE_REQUEST: | 307 | case EVENT_FULLSCRAPE_REQUEST: |
308 | { | 308 | { |
309 | char ip[4]; *(int*)ip = is_tcp; /* ugly hack to transfer ip to stats */ | 309 | unsigned char ip[4]; *(int*)ip = is_tcp; /* ugly hack to transfer ip to stats */ |
310 | LOG_TO_STDERR( "[%08d] scrp: %d.%d.%d.%d - FULL SCRAPE\n", (unsigned int)(g_now - ot_start_time), ip[0], ip[1], ip[2], ip[3] ); | 310 | LOG_TO_STDERR( "[%08d] scrp: %d.%d.%d.%d - FULL SCRAPE\n", (unsigned int)(g_now - ot_start_time), ip[0], ip[1], ip[2], ip[3] ); |
311 | ot_full_scrape_request_count++; | 311 | ot_full_scrape_request_count++; |
312 | } | 312 | } |
313 | break; | 313 | break; |
314 | case EVENT_FULLSCRAPE_REQUEST_GZIP: | 314 | case EVENT_FULLSCRAPE_REQUEST_GZIP: |
315 | { | 315 | { |
316 | char ip[4]; *(int*)ip = is_tcp; /* ugly hack to transfer ip to stats */ | 316 | unsigned char ip[4]; *(int*)ip = is_tcp; /* ugly hack to transfer ip to stats */ |
317 | LOG_TO_STDERR( "[%08d] scrp: %d.%d.%d.%d - FULL SCRAPE GZIP\n", (unsigned int)(g_now - ot_start_time), ip[0], ip[1], ip[2], ip[3] ); | 317 | LOG_TO_STDERR( "[%08d] scrp: %d.%d.%d.%d - FULL SCRAPE GZIP\n", (unsigned int)(g_now - ot_start_time), ip[0], ip[1], ip[2], ip[3] ); |
318 | ot_full_scrape_request_count++; | 318 | ot_full_scrape_request_count++; |
319 | } | 319 | } |