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/22673] New: The limit of examining characters in mode of fdopen is hardcoded to 7.


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

            Bug ID: 22673
           Summary: The limit of examining characters in mode of fdopen
                    is hardcoded to 7.
           Product: glibc
           Version: 2.26
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: stdio
          Assignee: unassigned at sourceware dot org
          Reporter: kshitijwarungase at gmail dot com
                CC: kshitijwarungase at gmail dot com
  Target Milestone: ---

When  parsing  for  individual flag characters in mode (i.e., the characters
preceding the "ccs" specification), the  glibc implementation  of fopen() and
freopen() limits the number of characters examined in mode  to  7  (or,  in 
glibc  versions before  2.14,  to 6, which was not enough to include possible
specifications such as "rb+cmxe").  The  current  implementation of fdopen()
parses at most 5 characters in mode.

We can make the examination of charactrs in mode generic with conditional loop
instead of fix iteration.

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