Ignore UDP errors in VoiceSocket's outgoing thread, and push them to the log.

This commit is contained in:
RogueException
2015-11-26 20:51:16 -04:00
parent 4d2f1e1bae
commit e189fa2461

View File

@@ -388,7 +388,14 @@ namespace Discord.Net.WebSockets
{
if (hasFrame)
{
_udp.Send(voicePacket, rtpPacketLength);
try
{
_udp.Send(voicePacket, rtpPacketLength);
}
catch (SocketException ex)
{
RaiseOnLog(LogMessageSeverity.Error, "Failed to send UDP packet.", ex);
}
hasFrame = false;
}
nextTicks += ticksPerFrame;