patacongo commented on PR #9151: URL: https://github.com/apache/nuttx/pull/9151#issuecomment-1531535641
The OS code must never set the errno value. This change would violate that rule since these memory management functions are called within the kernel in all build modes. Within the kernel, it will, for example, define umm_realloc() to be realloc() and in the FLAT build kmm_realloc() will also be defined to be realloc(). Other combinations are possible in other build modes but In every case, the function called by the kernel _must not change the errno value. See Issue #1027 is ongoing issue (that could probably be closed now). Normally this is would be accomplished by creating a separate nx* function that does not set the errno value so realloc() would call mm_realloc() which would call nx_realloc() where mm_realloc() sets the errno. The kernal would call only nx_realloc(). Since ma -- 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]
