Open emilydaemon opened 1 week ago
hey emily!
just took a quick look, and it seems the parameters are unused ( https://github.com/devkitPro/libogc/blob/master/libogc/network_wii.c#L1192 ) ! question is though, are they retrieved in the ios calls... ill have to dig deeper!
EDIT : look like it'll need to be retrieved from IOS using some calls like it does for the ip : https://github.com/devkitPro/libogc/blob/master/libogc/network_wii.c#L304
the wiibrew documentation is very... bare for the network stuff. maybe we can find this stuff somewhere else ?
found something in dolphin. IOS' /dev/net/ip/top device has a IOCTLV called GetInterfaceOption that can retrieve the ip, gateway and subnet mask given the right sub command id. i think our GetHostIp call needs to be replaced with this. source : https://github.com/dolphin-emu/dolphin/blob/master/Source/Core/Core/IOS/Network/IP/Top.cpp#L981-L991
got the call implemented. need to clean up my code and fix dolphin's implementation of the ioctlv :) gateway isn't right though, thats the wifi broadcast ip.. :/
Bug Report
What's the issue you encountered?
network_wii's if_config function does not populate netmask or gateway, even though these are accepted as parameters. I expected them to be populated with subnet mask and default gateway respectively, but the function does not make any changes to them.
How can the issue be reproduced?
TRUE
and20
.192.168.68.52
), but the second and third arrays are left unchanged.Environment?
I am using Windows 10 with the supplied msys2 shell, but I do not believe that this is relevant to the problem.