This is the mail archive of the glibc-bugs@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug stdio/17576] New: stdin/stdout/stderr namespace


https://sourceware.org/bugzilla/show_bug.cgi?id=17576

            Bug ID: 17576
           Summary: stdin/stdout/stderr namespace
           Product: glibc
           Version: 2.21
            Status: NEW
          Severity: normal
          Priority: P2
         Component: stdio
          Assignee: unassigned at sourceware dot org
          Reporter: jsm28 at gcc dot gnu.org

glibc defines stdin, stdout and stderr as extern FILE * variables in libc (with
associated macros "#define stdin stdin" etc.).

As ISO C defines these as macros, they may be reserved with external linkage if
<stdio.h> is included (this isn't entirely clear), but not otherwise.  Thus (a)
internal uses of these from within libc should use the _IO_stdin etc. internal
names (some do, but not consistently) and (b) stdin, stdout, stderr should be
weak symbols.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]