2007-08-10 Michael Snyder <msnyder@access-company.com>

* stabsread.c (read_huge_number): Attempt to compute value before
	values that it depends on.
This commit is contained in:
Michael Snyder
2007-08-10 22:08:22 +00:00
parent 46be51c450
commit 6aef78af04
2 changed files with 5 additions and 1 deletions

View File

@@ -1,5 +1,8 @@
2007-08-10 Michael Snyder <msnyder@access-company.com>
* stabsread.c (read_huge_number): Attempt to compute value before
values that it depends on.
* linespec.c (decode_dollar): Dead code, ptr can't be non-null.
(decode_objc): Use "NULL" instead of 0.
(find_method): Ditto.

View File

@@ -3714,7 +3714,7 @@ read_huge_number (char **pp, int end, int *bits, int twos_complement_bits)
int nbits = 0;
int c;
long upper_limit;
int twos_complement_representation = radix == 8 && twos_complement_bits > 0;
int twos_complement_representation;
if (*p == '-')
{
@@ -3730,6 +3730,7 @@ read_huge_number (char **pp, int end, int *bits, int twos_complement_bits)
p++;
}
twos_complement_representation = radix == 8 && twos_complement_bits > 0;
upper_limit = LONG_MAX / radix;
while ((c = *p++) >= '0' && c < ('0' + radix))