This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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 preprocessor/30001] New: out-of-bounds access when processing empty file


valgrind on Linux the reports the following error: Invalid read of size 1 for
the function _cpp_convert_input (at line 1631 in charset.c) when an empty
source file is compiled.

libcpp/charset.c:_cpp_convert_input line 1631 is:
  if (to.text[to.len - 1] == '\r')
and if to.len is zero, this is an out-of-bounds access.


-- 
           Summary: out-of-bounds access when processing empty file
           Product: gcc
           Version: 4.3.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: preprocessor
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: amylaar at gcc dot gnu dot org
OtherBugsDependingO 29842
             nThis:


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=30001


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