Using the new Arduino IDE for ESP8266 and found bugs, report them here

Moderator: igrr

User avatar
By inx
#15019 Hello.

I am testing with a slightly modified version of the WifiWebServer example to receive data.
After a while sending data it crashes, the last line beeing:

Code: Select allFatal exception (9):


i added this to WifiServer.h:
Code: Select allbool isAvailable() { return _unclaimed != 0; };


this is my loop():
Code: Select all  while (server.isAvailable()) {
 
    WiFiClient client = server.available();
    if (!client) {
      return;
    }
   
    // Wait until the client sends some data
    Serial.println("new client");
    while(!client.available()){
      delay(1);
    }
   
    // Read the first line of the request
    String req = client.readStringUntil(10);
    Serial.println(req);
    client.flush();
  }


what is exception (9)?
what can i do to improve this?

might it be that an unclaimed client is already used while it is added to the _unclaimed list?
(looking at WifiServer.cpp line 132 and 84)