1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

util.c: suppress warnings

These functions handle overflows correctly.



git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65643 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
shyouhei 2018-11-09 09:44:49 +00:00
parent b8540e0a9d
commit 1922253e2e

2
util.c
View file

@ -84,6 +84,7 @@ const signed char ruby_digit36_to_number_table[] = {
/*f*/ -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,
};
NO_SANITIZE("unsigned-integer-overflow", extern unsigned long ruby_scan_digits(const char *str, ssize_t len, int base, size_t *retlen, int *overflow));
unsigned long
ruby_scan_digits(const char *str, ssize_t len, int base, size_t *retlen, int *overflow)
{
@ -2970,6 +2971,7 @@ ret:
return sign ? -dval(rv) : dval(rv);
}
NO_SANITIZE("unsigned-integer-overflow", static int quorem(Bigint *b, Bigint *S));
static int
quorem(Bigint *b, Bigint *S)
{