-
Notifications
You must be signed in to change notification settings - Fork 457
Binding to "any" address does not work as expected #1037
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
Comments
chrysn
added a commit
to chrysn-pull-requests/RIOT-rs
that referenced
this issue
Jan 27, 2025
4 tasks
chrysn
added a commit
to chrysn-pull-requests/RIOT-rs
that referenced
this issue
Jan 27, 2025
this is intended behavior, see #981 |
Fine with me, sorry for the duplicate. That's an argument that will also be helpful in rust-embedded-community/embedded-nal#92 -- indicating that the core types are a tad too far on the "POSIX sockets" side of things, with more idiomatic expressions around (esp. when the IP addresses are expressed in such a way that they have a zero niche). |
ROMemories
pushed a commit
to ROMemories/ariel-os
that referenced
this issue
Jan 27, 2025
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
At least on UDP sockets, calling
socket.bind(IpEndpoint::from(core::net::SocketAddr::parse("0.0.0.0:1234").unwrap()))
does not behave as expected: It seems to bind not at all, whereas it should bind to that port on any IP address.There is a workaround of doing
socket.bind(1234)
-- that's fine when an application calls it directly, but needs a workaround such as(And sorry for the IPv4 examples, we're working to have v6 in parallel)
I can most probably provide a PR later; right now, this serves to document the workaround.
The text was updated successfully, but these errors were encountered: