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 c/67410] New: c/c-typeck.c references out of bounds array


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67410

            Bug ID: 67410
           Summary: c/c-typeck.c references out of bounds array
           Product: gcc
           Version: 5.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zeccav at gmail dot com
  Target Milestone: ---

/*sanitizer message*/
/*gcc-5.2.0/gcc/c/c-typeck.c:8266:42: runtime error: load of address
0x7ffc8682b570 with insufficient space for an object of type 'long int'*/
/*gcc-5.2.0/gcc/c/c-typeck.c:8266:42: runtime error: store to address
0x7ffc8682b570 with insufficient space for an object of type 'long int'*/
/*offending source line "val[bitpos % HOST_BITS_PER_WIDE_INT]"
 * val is dimensioned [2] but bitpos % HOST_BITS_PER_WIDE_INT == 8 
 * double check with "gcc_assert(bitpos % HOST_BITS_PER_WIDE_INT<2);"
 * Target: x86_64-unknown-linux-gnu */
struct {
  __CHAR16_TYPE__ S[1];
} a[] = {   u"f"  , [0].S[0] = u'x' };


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