ricardgb commented on code in PR #3658:
URL: https://github.com/apache/nuttx-apps/pull/3658#discussion_r3644250140


##########
netutils/telnetd/telnetd_daemon.c:
##########
@@ -126,12 +126,11 @@ int telnetd_daemon(FAR const struct telnetd_config_s 
*config)
     }
 
   /* If the daemon was started without standard streams (e.g. spawned by
-   * nsh_telnetstart() before a USB console device exists), socket() may
-   * have returned a descriptor in 0..2.  The "go silent"
-   * close(0)..close(2) at the top of the accept loop below would then
-   * destroy the listen socket: every subsequent accept4() fails and the
-   * daemon serves nothing.  Move the descriptor above the
-   * standard-stream range.
+   * nsh_telnetstart() before a USB console exists), socket() may have

Review Comment:
   Thanks @xiaoxiang781216 . Good questions on the accept-loop error handling —
   I'd like to hold this one briefly before I revise it. I'm coordinating a
   related change with the maintainers and want the daemon's error handling to
   line up with it rather than reworking this twice. I'll follow up here with 
the
   updates (the fatal-vs-transient split, the sleep, and folding the comment
   change into the earlier commit) once that's settled. Appreciate the review.



-- 
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]

Reply via email to