Skip to content

Commit 1e96e65

Browse files
mkillewaldincowizglenlee
authored andcommitted
small fix to stop crash on unrecognized packets (esp8266#4092)
1 parent b2f9fca commit 1e96e65

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

libraries/ArduinoOTA/ArduinoOTA.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ int ArduinoOTAClass::parseInt(){
149149
for(index = 0; index < sizeof(data); ++index){
150150
value = _udp_ota->peek();
151151
if(value < '0' || value > '9'){
152-
data[index++] = '\0';
152+
data[index] = '\0';
153153
return atoi(data);
154154
}
155155
data[index] = _udp_ota->read();

0 commit comments

Comments
 (0)