Lines Matching refs:inseg

62 static struct tcp_seg inseg;
280 inseg.next = NULL;
281 inseg.len = p->tot_len;
282 inseg.p = p;
283 inseg.tcphdr = tcphdr;
397 /* give up our reference to inseg.p */
398 if (inseg.p != NULL)
400 pbuf_free(inseg.p);
401 inseg.p = NULL;
689 LWIP_DEBUGF(TCP_DEBUG, ("TCP connection established %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest));
744 ("TCP connection closed: FIN_WAIT_1 %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest));
761 LWIP_DEBUGF(TCP_DEBUG, ("TCP connection closed: FIN_WAIT_2 %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest));
772 LWIP_DEBUGF(TCP_DEBUG, ("TCP connection closed: CLOSING %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest));
782 LWIP_DEBUGF(TCP_DEBUG, ("TCP connection closed: LAST_ACK %"U16_F" -> %"U16_F".\n", inseg.tcphdr->src, inseg.tcphdr->dest));
1159 the pbuf chain is pointed to by inseg.p. Since we need to be
1161 inseg.p pointer to point to any of the later pbufs in the
1164 inseg.data pointer to point to the right place. This way, the
1173 p = inseg.p;
1174 LWIP_ASSERT("inseg.p != NULL", inseg.p);
1176 if (inseg.p->len < off) {
1177 LWIP_ASSERT("pbuf too short!", (((s32_t)inseg.p->tot_len) >= off));
1178 new_tot_len = (u16_t)(inseg.p->tot_len - off);
1183 inseg.p->tot_len -= p->len; */
1193 if(pbuf_header(inseg.p, (s16_t)-off)) {
1198 inseg.len -= (u16_t)(pcb->rcv_nxt - seqno);
1199 inseg.tcphdr->seqno = seqno = pcb->rcv_nxt;
1220 tcplen = TCP_TCPLEN(&inseg);
1227 if (TCPH_FLAGS(inseg.tcphdr) & TCP_FIN) {
1230 TCPH_FLAGS_SET(inseg.tcphdr, TCPH_FLAGS(inseg.tcphdr) &~ TCP_FIN);
1233 inseg.len = pcb->rcv_wnd;
1234 if (TCPH_FLAGS(inseg.tcphdr) & TCP_SYN) {
1235 inseg.len -= 1;
1237 pbuf_realloc(inseg.p, inseg.len);
1238 tcplen = TCP_TCPLEN(&inseg);
1247 if (TCPH_FLAGS(inseg.tcphdr) & TCP_FIN) {
1260 /* Remove all segments on ooseq that are covered by inseg already.
1261 * FIN is copied from ooseq to inseg if present. */
1265 /* inseg cannot have FIN here (already processed above) */
1267 (TCPH_FLAGS(inseg.tcphdr) & TCP_SYN) == 0) {
1268 TCPH_SET_FLAG(inseg.tcphdr, TCP_FIN);
1269 tcplen = TCP_TCPLEN(&inseg);
1275 /* Now trim right side of inseg if it overlaps with the first
1280 /* inseg cannot have FIN here (already processed above) */
1281 inseg.len = (u16_t)(next->tcphdr->seqno - seqno);
1282 if (TCPH_FLAGS(inseg.tcphdr) & TCP_SYN) {
1283 inseg.len -= 1;
1285 pbuf_realloc(inseg.p, inseg.len);
1286 tcplen = TCP_TCPLEN(&inseg);
1312 if (inseg.p->tot_len > 0) {
1313 recv_data = inseg.p;
1317 inseg.p = NULL;
1319 if (TCPH_FLAGS(inseg.tcphdr) & TCP_FIN) {
1373 pcb->ooseq = tcp_seg_copy(&inseg);
1394 if (inseg.len > next->len) {
1398 cseg = tcp_seg_copy(&inseg);
1421 cseg = tcp_seg_copy(&inseg);
1437 cseg = tcp_seg_copy(&inseg);
1459 next->next = tcp_seg_copy(&inseg);