From: Alan Modra Date: Sat, 1 Jan 2022 03:23:32 +0000 (+1030) Subject: ubsan: next_char_of_string signed integer overflow X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=b685de86cc42cec995c38c042a4377be471fc77b;p=binutils-gdb.git ubsan: next_char_of_string signed integer overflow Squash another totally useless fuzz report that I should have ignored. * read.c (next_char_of_string): Avoid integer overflow. --- diff --git a/gas/read.c b/gas/read.c index cd82c83adeb..6c8b7c3efdb 100644 --- a/gas/read.c +++ b/gas/read.c @@ -5642,7 +5642,7 @@ next_char_of_string (void) case '8': case '9': { - long number; + unsigned number; int i; for (i = 0, number = 0; @@ -5660,7 +5660,7 @@ next_char_of_string (void) case 'x': case 'X': { - long number; + unsigned number; number = 0; c = *input_line_pointer++;