mirror of
https://github.com/esp8266/Arduino.git
synced 2025-04-19 23:22:16 +03:00
Merge pull request #1880 from sauttefk/master
Re-enable old behaviour if passphrase string is empty
This commit is contained in:
commit
fa7e9037a4
@ -89,13 +89,13 @@ bool ESP8266WiFiAPClass::softAP(const char* ssid, const char* passphrase, int ch
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!ssid || *ssid == 0 || strlen(ssid) > 31) {
|
if(!ssid || strlen(ssid) == 0 || strlen(ssid) > 31) {
|
||||||
// fail SSID too long or missing!
|
// fail SSID too long or missing!
|
||||||
DEBUG_WIFI("[AP] SSID too long or missing!\n");
|
DEBUG_WIFI("[AP] SSID too long or missing!\n");
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if(passphrase && (strlen(passphrase) > 63 || strlen(passphrase) < 8)) {
|
if(passphrase && strlen(passphrase) > 0 && (strlen(passphrase) > 63 || strlen(passphrase) < 8)) {
|
||||||
// fail passphrase to long or short!
|
// fail passphrase to long or short!
|
||||||
DEBUG_WIFI("[AP] fail passphrase to long or short!\n");
|
DEBUG_WIFI("[AP] fail passphrase to long or short!\n");
|
||||||
return false;
|
return false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user