提交 cde668da 编写于 作者: L lbernstone 提交者: Me No Dev

ArduinoOTA endless loop (#1533)

* Changed pinmap to show pins34-39 as GPI

* ArduinoOTA could have endless loop b/c udp.read can return negative result
上级 a59eafbc
......@@ -149,13 +149,13 @@ int ArduinoOTAClass::parseInt(){
String ArduinoOTAClass::readStringUntil(char end){
String res = "";
char value;
int value;
while(true){
value = _udp_ota.read();
if(value == '\0' || value == end){
if(value <= 0 || value == end){
return res;
}
res += value;
res += (char)value;
}
return res;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册