Merge remote-tracking branch 'origin/master'

This commit is contained in:
Him188 2019-10-10 11:30:28 +08:00
commit ff6403cd87

View File

@ -127,19 +127,11 @@ internal class TIMBotNetworkHandler(private val bot: Bot) : BotNetworkHandler {
return
}
withContext(CoroutineExceptionHandler { _, e -> e.printStackTrace() }) {
launch(this.coroutineContext) {
loginHandler.onPacketReceived(packet)
}
packetHandlers.forEach {
launch(this.coroutineContext) {
it.instance.onPacketReceived(packet)
}
}
}//awaits all coroutines launched in this block
}
private var socket: DatagramSocket? = null