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 sanitizer/82072] New: sanitizer does not detect on overflow from LLONG_MIN


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

            Bug ID: 82072
           Summary: sanitizer does not detect on overflow from LLONG_MIN
           Product: gcc
           Version: 8.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: sanitizer
          Assignee: unassigned at gcc dot gnu.org
          Reporter: zeccav at gmail dot com
                CC: dodji at gcc dot gnu.org, dvyukov at gcc dot gnu.org,
                    jakub at gcc dot gnu.org, kcc at gcc dot gnu.org, marxin at gcc dot gnu.org
  Target Milestone: ---
              Host: x86_64-pc-linux-gnu
             Build: trunk 251201

/* sanitizer should emit runtime error messages */
#include <limits.h>
int main()
{
long lmin=LLONG_MIN;
int  i=0;
i -= lmin; /*signed integer overflow*/
i = -lmin; /*negation of -9223372036854775808 cannot be represented in type
'long'*/
return 0;
}

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