Log host and port when unexpected or unknown UDP tracker reply is received

pull/46/head
Tatsuhiro Tsujikawa 2013-02-25 01:14:27 +09:00
parent d68741697a
commit 2aeb7137d0
1 changed files with 4 additions and 2 deletions

View File

@ -235,10 +235,12 @@ int UDPTrackerClient::receiveReply
break;
}
case UDPT_ACT_SCRAPE:
A2_LOG_INFO("unexpected scrape action reply");
A2_LOG_INFO(fmt("unexpected scrape action reply from %s:%u",
remoteAddr.c_str(), remotePort));
return -1;
default:
A2_LOG_INFO("unknown action reply");
A2_LOG_INFO(fmt("unknown action reply from %s:%u",
remoteAddr.c_str(), remotePort));
return -1;
}
return 0;