mirror of
https://github.com/fastfetch-cli/fastfetch.git
synced 2026-09-13 02:42:09 +02:00
Wifi: fix code smells
This commit is contained in:
@@ -38,7 +38,7 @@ static bool getWifiInfoByIpconfig(FFstrbuf* ipconfig, const char* prefix, FFstrb
|
||||
const char* end = strchr(start, '\n');
|
||||
if (!end) return false;
|
||||
ffStrbufSetNS(result, (uint32_t) (end - start), start);
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
const char* ffDetectWifi(FFlist* result)
|
||||
|
||||
@@ -98,6 +98,10 @@ const char* ffDetectWifi(FFlist* result)
|
||||
ffStrbufSetStatic(&item->conn.protocol, "802.11n (Wi-Fi 4)");
|
||||
if (IEEE80211_IS_CHAN_VHT(&curchan))
|
||||
ffStrbufSetStatic(&item->conn.protocol, "802.11ac (Wi-Fi 5)");
|
||||
#ifdef IEEE80211_IS_CHAN_HE // for future use
|
||||
if (IEEE80211_IS_CHAN_HE(&curchan))
|
||||
ffStrbufSetStatic(&item->conn.protocol, "802.11ax (Wi-Fi 6)");
|
||||
#endif
|
||||
}
|
||||
|
||||
union {
|
||||
|
||||
Reference in New Issue
Block a user