You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/03/15 00:43:53 UTC

[GitHub] [incubator-nuttx] codebje commented on pull request #3054: tools/mksymtab: support non-function symbols

codebje commented on pull request #3054:
URL: https://github.com/apache/incubator-nuttx/pull/3054#issuecomment-799017208


   I've reverted the underscore changes, leaving only the non-function symbols change. This itself merits some discussion: I made this change to support adding `optarg` and `optind` to `libc.csv`. These globals are used by `nsh` in several modules and by a handful of system applications.
   
   I'm nevertheless closing this PR, because I don't think this is the right way to deal with the problem - in a flat build `getopt()` is shared across all processes, and is not safe to use (there's an existing race condition in the builtins using it, eg). In a protected build `getopt()` is shared across user space and is similarly not safe.
   
   This problem occurs in several places in libc. It's documented in `libs/libc/syslog/lib_setlogmask.c`, and exists in enough places that a more general solution is likely needed.


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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org