1
0
mirror of https://github.com/esp8266/Arduino.git synced 2025-07-10 04:22:05 +03:00

Pass timeout to optimistic_yield, add cont_can_yield check

This commit is contained in:
Ivan Grokhotkov
2015-07-20 15:48:25 +03:00
parent 01361fc4c8
commit e5d2ba5db8
11 changed files with 193 additions and 177 deletions

View File

@ -1,10 +1,10 @@
/*
/*
WiFiServer.cpp - TCP/IP server for esp8266, mostly compatible
with Arduino WiFi shield library
Copyright (c) 2014 Ivan Grokhotkov. All rights reserved.
This file is part of the esp8266 core for Arduino environment.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
@ -99,7 +99,7 @@ WiFiClient WiFiServer::available(byte* status)
return result;
}
optimistic_yield();
optimistic_yield(1000);
return WiFiClient();
}
@ -161,4 +161,3 @@ void WiFiServer::_s_discard(void* server, ClientContext* ctx)
{
reinterpret_cast<WiFiServer*>(server)->_discard(ctx);
}