Yortw / RSSDP

Really Simple Service Discovery Protocol - a 100% .Net implementation of the SSDP protocol for publishing custom/basic devices, and discovering all device types on a network.
http://yortw.github.io/RSSDP/
MIT License
288 stars 67 forks source link

Unhandled exception when UdpSocket is disposed but inner disposed socket receives an input #104

Open gelexgaray opened 4 years ago

gelexgaray commented 4 years ago

on public System.Threading.Tasks.Task ReceiveAsync()

When the UdpSocket is disposed and the inner socket is also disposed, ReceiveAsync raises a DisposedException on network input. It shouldn't raise any exception in this case.

This is managed in the NETSTANDARD1.3 code, but not in the rest of the variants of the code

I will send you a pull request with a fix proposal