-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LinuxNetworkInterface.GetLinuxNetworkInterfaces - An invalid IP address was specified #42
Comments
… GetLinuxNetworkInterfaces
@bruinsg It would be nice if we can find out why this is crashing. Can you run your application with strace up until the point it crashes:
Can you share the |
@tmds This is not about data being received, it happens during in the NetworkAvailabilityHandler. My application is an embedded device and during a major software update the kernel is being changed. At this point the NetworkAvailabiltyHandler starts receiving notifications every 1-2 seconds. The handler calls the NetworkInterface.GetAllNetworkInterfaces() which has an issue, dotnet/runtime#49515, in it and can throw an exception. I can't handle the exception in my application as it inside the library. In my opinion we can't fix this bug, we can only catch the exception. It is rare and very hard to reproduce as the full upgrade takes about 30 minutes and the exception has only been reported 3 times. (out of 100s of tests) |
I know. The
Maybe you can try running a .NET app that calls |
@tmds I have been trying to reproduce this without much success. To be honest, I am not sure why we need to find the root cause for this as it is not an issue with the Mdns library but a generic dotnet issue. My fix is merely a workaround of the dotnet/runtime#49515 issue |
Thank you for trying. I'll take a closer look at the PR.
If we were able to reproduce the issue we probably could have contributed a fix for it. |
My application crashed due to an issue reported on github for the dotnet runtime. See: dotnet/runtime#49515
Stacktrace:
System.ArgumentException: An invalid IP address was specified. (Parameter 'address')
at System.Net.IPAddress..ctor(ReadOnlySpan
1 address) at System.Net.NetworkInformation.LinuxNetworkInterface.GetLinuxNetworkInterfaces() at Tmds.MDns.ServiceBrowser.CheckNetworkInterfaceStatuses(Dictionary
2 interfaceHandlers)at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location ---
at System.Net.NetworkInformation.NetworkChange.OnAvailabilityTimerFired(Object state)
at System.Threading.TimerQueueTimer.Fire(Boolean isThreadPool)
at System.Threading.TimerQueue.FireNextTimers()
The text was updated successfully, but these errors were encountered: