File tree 3 files changed +18
-0
lines changed
3 files changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -26,6 +26,12 @@ config LWIP_GLOBAL_DATA_LINK_IRAM
26
26
help
27
27
Link LWIP global data(.bss .data COMMON) from DRAM to IRAM.
28
28
29
+ config ESP_LWIP_RECV_REST_DATA
30
+ bool "Receive rest data although TCP aborts"
31
+ default n
32
+ help
33
+ Receive rest data although TCP aborts.
34
+
29
35
config TCPIP_RECVMBOX_SIZE
30
36
int "TCPIP task receive mail box size"
31
37
default 32
Original file line number Diff line number Diff line change @@ -500,13 +500,19 @@ netconn_recv_data(struct netconn *conn, void **new_buf)
500
500
#endif /* LWIP_TCP */
501
501
LWIP_ERROR ("netconn_recv: invalid recvmbox" , sys_mbox_valid (& conn -> recvmbox ), return ERR_CONN ;);
502
502
503
+ #if ESP_LWIP_RECV_REST_DATA
504
+ if (!sys_mbox_valid (& conn -> recvmbox )) {
505
+ #endif
503
506
if (ERR_IS_FATAL (conn -> last_err )) {
504
507
/* don't recv on fatal errors: this might block the application task
505
508
waiting on recvmbox forever! */
506
509
/* @todo: this does not allow us to fetch data that has been put into recvmbox
507
510
before the fatal error occurred - is that a problem? */
508
511
return conn -> last_err ;
509
512
}
513
+ #if ESP_LWIP_RECV_REST_DATA
514
+ }
515
+ #endif
510
516
#if LWIP_TCP
511
517
#if (LWIP_UDP || LWIP_RAW )
512
518
if (NETCONNTYPE_GROUP (conn -> type ) == NETCONN_TCP )
Original file line number Diff line number Diff line change 82
82
#define ESP_NONBLOCK 0
83
83
#endif
84
84
85
+ #ifdef CONFIG_ESP_LWIP_RECV_REST_DATA
86
+ #define ESP_LWIP_RECV_REST_DATA 1
87
+ #else
88
+ #define ESP_LWIP_RECV_REST_DATA 0
89
+ #endif
90
+
85
91
//#define SOCKETS_TCP_TRACE
86
92
87
93
#define TCP_HIGH_SPEED_RETRANSMISSION CONFIG_TCP_HIGH_SPEED_RETRANSMISSION
You can’t perform that action at this time.
0 commit comments