Skip to content
This repository has been archived by the owner on May 14, 2021. It is now read-only.

Commit

Permalink
build fix for 386 platform (disabled wifiNotifier)
Browse files Browse the repository at this point in the history
  • Loading branch information
stenya committed Nov 6, 2020
1 parent f957b3f commit 7db45f0
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 2 deletions.
2 changes: 1 addition & 1 deletion wifiNotifier/wifiNotifier_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ func GetCurrentSSID() string {
// GetCurrentNetworkSecurity returns current security mode
func GetCurrentNetworkSecurity() WiFiSecurity {
// TODO: implement getCurrentNetworkSecurity functionality
return 0xFFFFFFFF
return 0xFFFF

// ret := WiFiSecurityUnknown
// if C.getCurrentNetworkIsInsecure() == 1 {
Expand Down
23 changes: 23 additions & 0 deletions wifiNotifier/wifiNotifier_windows_386.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
// +build windows

package wifiNotifier

// GetAvailableSSIDs returns the list of the names of available Wi-Fi networks
func GetAvailableSSIDs() []string {
return nil
}

// GetCurrentSSID returns current WiFi SSID
func GetCurrentSSID() string {
return ""
}

// GetCurrentNetworkSecurity returns current security mode
func GetCurrentNetworkSecurity() WiFiSecurity {
return WiFiSecurityUnknown
}

// SetWifiNotifier initializes a handler method 'OnWifiChanged'
func SetWifiNotifier(cb func(string)) {

}
2 changes: 1 addition & 1 deletion wifiNotifier/wifiSecurity.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ const (
WiFiSecurityWPAEnterpriseMixed WiFiSecurity = 8
WiFiSecurityWPA2Enterprise WiFiSecurity = 9
WiFiSecurityEnterprise WiFiSecurity = 10*/
WiFiSecurityUnknown WiFiSecurity = 0xFFFFFFFF
WiFiSecurityUnknown WiFiSecurity = 0xFFFF
)

0 comments on commit 7db45f0

Please sign in to comment.