xiaoxiang781216 commented on PR #3859:
URL: https://github.com/apache/nuttx-apps/pull/3859#issuecomment-6299388715

   > Hi @xiaoxiang781216,
   > 
   > You are right that this is an upstream Duktape cmdline limitation. However:
   > 
   > 1. The upstream Duktape repository (v2.5.0) is largely inactive/dormant, 
so an upstream fix is unlikely to be released or backported anytime soon.
   > 2. NuttX already carries `duk_cmdline.patch` specifically to adapt 
`duk_cmdline.c` and `duk_config.h` for NuttX environments (e.g. `LINEBUF_SIZE` 
and date/time configs).
   > 3. On flat-memory/RTOS targets like ESP32, an unhandled SIGINT aborts the 
task and leaks Duktape's heap, making subsequent runs immediately crash the 
board ([[BUG] Duktape crashes while you try to start it after interrupting it 
with ctrl+c. #2855](https://github.com/apache/nuttx-apps/issues/2855)).
   > 
   > Since we already maintain `duk_cmdline.patch` in tree, this change simply 
leverages Duktape's existing timeout/interrupt hooks within our patch to make 
`duk` usable and safe from board panics on NuttX.
   > 
   > Would you prefer keeping this in our downstream patch, or do you suggest 
an alternative approach (e.g., an external wrapper)?
   
   ok, but please remove the unnecessary change from the patch file.


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