xiaoxiang781216 commented on PR #12969:
URL: https://github.com/apache/nuttx/pull/12969#issuecomment-2295901905

   > You're trading stack usage for heap fragmentation.
   
   the allocation doesn't happen if the concurrent usage doesn't exceed 
CONFIG_LIBC_MAX_PATHBUFFER.
   
   > I disagree with this approach because once your heap is to fragmented 
`malloc` would simply fail and your system most likely crashes. if you really 
want it I propose you make an optional kconfig symbol called i.e. `dynamic path 
allocation`
   
   if you want, we can add an option to skip the allocation and return NULL 
directly if the usage exceeds CONFIG_LIBC_MAX_PATHBUFFER.


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