recv_data = NULL;
recv_flags = 0;
+ if (flags & TCP_PSH) {
+ p->flags |= PBUF_FLAG_PUSH;
+ }
+
/* If there is data which was previously "refused" by upper layer */
if (pcb->refused_data != NULL) {
/* Notify again application with data previously received. */
tcp_abort(pcb);
goto aborted;
}
- if (flags & TCP_PSH) {
- recv_data->flags |= PBUF_FLAG_PUSH;
- }
/* Notify application that data has been received. */
TCP_EVENT_RECV(pcb, recv_data, ERR_OK, err);