The WlanEnumInterfaces
populates the field you provide it with the address of a struct. You are passing in the address of a struct rather than the address of an address.
Use PointerByReference
to get the address of the struct, e.g.
PointerByReference pref = new PointerByReference();
Wlanapi.INSTANCE.WlanEnumInterfaces(handle, null, pref);
WLAN_INTERFACE_INFO_LIST list = new WLAN_INTERFACE_INFO_LIST(pref.getValue());
Then you need a Pointer
-based constructor for WLAN_INTERFACE_INFO_LIST
, i.e.
WLAN_INTERFACE_INFO_LIST(Pointer p) {
super(p);
this.dwNumberOfItems = p.readInt(0);
this.InterfaceInfo = new WLAN_INTERFACE_INFO[this.dwNumberOfItems];
read();
}