File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed
libraries/ESP8266WiFi/src/include Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -191,7 +191,8 @@ class ClientContext
191191 else if (!_rx_buf->next )
192192 {
193193 DEBUGV (" :c0 %d, %d\r\n " , size, _rx_buf->tot_len );
194- tcp_recved (_pcb, _rx_buf->len );
194+ if (_pcb)
195+ tcp_recved (_pcb, _rx_buf->len );
195196 pbuf_free (_rx_buf);
196197 _rx_buf = 0 ;
197198 _rx_buf_offset = 0 ;
@@ -203,7 +204,8 @@ class ClientContext
203204 _rx_buf = _rx_buf->next ;
204205 _rx_buf_offset = 0 ;
205206 pbuf_ref (_rx_buf);
206- tcp_recved (_pcb, head->len );
207+ if (_pcb)
208+ tcp_recved (_pcb, head->len );
207209 pbuf_free (head);
208210 }
209211 }
@@ -218,8 +220,8 @@ class ClientContext
218220 tcp_sent (pcb, NULL );
219221 tcp_recv (pcb, NULL );
220222 tcp_err (pcb, NULL );
221- int error = tcp_close (pcb);
222- if (error != ERR_OK)
223+ // int error = tcp_close(pcb);
224+ // if (error != ERR_OK)
223225 {
224226 DEBUGV (" :rcla\r\n " );
225227 tcp_abort (pcb);
You can’t perform that action at this time.
0 commit comments