mirror of
https://github.com/SWG-Source/src.git
synced 2026-07-31 00:15:55 -04:00
fix more warnings
This commit is contained in:
@@ -2881,7 +2881,7 @@ void ChatInterface::OnReceivePersistentMessage(const ChatAvatar *destAvatar, con
|
||||
DEBUG_WARNING(true, ("We received an OnREceivePersistentMessage with a success result code but NULL data. This is an error that the API should never give."));
|
||||
return;
|
||||
}
|
||||
if (!destAvatar || !header)
|
||||
if (!header)
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -3020,10 +3020,6 @@ void ChatInterface::OnReceiveInstantMessage(const ChatAvatar *srcAvatar, const C
|
||||
DEBUG_WARNING(true, ("We received an OnReceiveInstantMessage with a success result code but NULL data. This is an error that the API should never give."));
|
||||
return;
|
||||
}
|
||||
if (!srcAvatar || !destAvatar)
|
||||
{
|
||||
return;
|
||||
}
|
||||
ChatAvatarId fromId;
|
||||
makeAvatarId(*srcAvatar, fromId);
|
||||
ChatAvatarId toId;
|
||||
|
||||
@@ -477,24 +477,17 @@ void ChatServer::onEnumerateServers(const EnumerateServers & e)
|
||||
|
||||
ConnectionServerConnection * c = new ConnectionServerConnection(e.getAddress(), e.getPort());
|
||||
|
||||
if (c != NULL)
|
||||
if ( !e.getAddress().empty()
|
||||
&& (e.getPort() != 0))
|
||||
{
|
||||
if ( !e.getAddress().empty()
|
||||
&& (e.getPort() != 0))
|
||||
{
|
||||
ChatServer::fileLog(true, "ChatServer", "onEnumerateServers() count(%d) address(%s)", count, getConnectionAddress(c).c_str());
|
||||
ChatServer::fileLog(true, "ChatServer", "onEnumerateServers() count(%d) address(%s)", count, getConnectionAddress(c).c_str());
|
||||
|
||||
IGNORE_RETURN(connectionServerConnections.insert(c));
|
||||
s_chatServerMetricsData->setConnectionServerConnectionCount(instance().connectionServerConnections.size());
|
||||
}
|
||||
else
|
||||
{
|
||||
ChatServer::fileLog(true, "ChatServer", "onEnumerateServers() count(%d) Empty server address", count);
|
||||
}
|
||||
IGNORE_RETURN(connectionServerConnections.insert(c));
|
||||
s_chatServerMetricsData->setConnectionServerConnectionCount(instance().connectionServerConnections.size());
|
||||
}
|
||||
else
|
||||
{
|
||||
ChatServer::fileLog(true, "ChatServer", "onEnumerateServers() count(%d) NULL connection", count);
|
||||
ChatServer::fileLog(true, "ChatServer", "onEnumerateServers() count(%d) Empty server address", count);
|
||||
}
|
||||
}//lint !e429 Custodial pointer 'c' (line 232) has not been freed or returned //jrandall tracked by connectionServerConnections
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user