Sarthak-Pandey commented on code in PR #20627:
URL: https://github.com/apache/nuttx/pull/20627#discussion_r4412219095
##########
net/tcp/tcp_input.c:
##########
@@ -1343,6 +1559,31 @@ static void tcp_input(FAR struct net_driver_s *dev,
uint8_t domain,
/* Queue out-of-order segments. */
tcp_input_ofosegs(dev, conn, iplen);
+#endif
+#ifdef CONFIG_NET_TCPURGDATA
+ /* RFC 793: If the URG bit is set in an out-of-order segment,
+ * announce the urgent pointer and notify listeners.
+ */
+
+ if ((tcp->flags & TCP_URG) != 0)
Review Comment:
Fixed. Cached `tcp->flags` and `tcp->urgp` into local stack variables
(`tcp_flags`, `urgp`) before calling `tcp_input_ofosegs()`, ensuring we don't
access the IOB buffer after it is trimmed/queued.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]