network: Replace a fatal_error with just error logging

This commit is contained in:
sfan5 2020-05-14 21:18:26 +02:00 committed by GitHub
parent 36d35f2fe3
commit d76785b4c7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 5 deletions

View File

@ -336,11 +336,9 @@ bool ConnectionSendThread::rawSendAsPacket(session_t peer_id, u8 channelnum,
{ {
PeerHelper peer = m_connection->getPeerNoEx(peer_id); PeerHelper peer = m_connection->getPeerNoEx(peer_id);
if (!peer) { if (!peer) {
LOG(dout_con << m_connection->getDesc() LOG(errorstream << m_connection->getDesc()
<< " INFO: dropped packet for non existent peer_id: " << " dropped " << (reliable ? "reliable " : "")
<< peer_id << std::endl); << "packet for non existent peer_id: " << peer_id << std::endl);
FATAL_ERROR_IF(!reliable,
"Trying to send raw packet reliable but no peer found!");
return false; return false;
} }
Channel *channel = &(dynamic_cast<UDPPeer *>(&peer)->channels[channelnum]); Channel *channel = &(dynamic_cast<UDPPeer *>(&peer)->channels[channelnum]);