-
Notifications
You must be signed in to change notification settings - Fork 852
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
SIOCGIFADDR, SIOCGIFNETMASK, SOCGIFBRDADDR not working #763
Comments
@cole15601 - Thanks for reporting this issue. WSL does currently support the SIOCGIFADDR, SIOCGIFNETMASK and SOCGIFBRDADDR , but only AF_INET sockets. Can you please share out full source so that we can repro it here locally? |
@sunilmut - I'm using AF_INET sockets. Test source is attached. Compile with
|
Seems it's fixed on insider build 14905. |
Great, how does one get that insider build? Any idea when it goes out for public consumption? |
For public expected release for next milestone should be March/April. WSL updates are coming to the Fast ring. To join in you need to go to Settings -> Update & Security -> Windows Insider Program and choose FAST ring. I don't recommend use them on your main PC though. It's better to use a VM or a Test PC/laptop as it can have bugs. (Shutdown StartMenu button doesn't work on build 14905 for example) |
Marking this as closed since it is fixed in the Insider builds. |
This maybe a duplicate of Issue #69, but SIOCGIFADDR et al are not working.
Sample source is:
strcpy(ifr.ifr_name, interface_name ); ifr.if_addr.sa_family=AF_INET; fd = socket(AF_INET,SOCK_DGRAM,IPPROTO_IP); if(ioctl(fd, SIOCGIFBRDADDR, &ifr) != -1) { //do something with the address } else { perror("Error getting IP:"); exit(-1); }
This produces the following output:
Error getting IP: Cannot assign requested address.
The text was updated successfully, but these errors were encountered: