diff --git a/ChangeLog b/ChangeLog index 6e29e2912..237c6f493 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2009-04-12 David S. Miller + + * kern/misc.c (grub_ltoa): Fix cast when handling negative + values. Noticed by Pavel Roskin. + 2009-04-12 Pavel Roskin * configure.ac: Change the logic when we check for target tools. diff --git a/kern/misc.c b/kern/misc.c index 85a5d9525..5a1253594 100644 --- a/kern/misc.c +++ b/kern/misc.c @@ -598,7 +598,7 @@ grub_ltoa (char *str, int c, unsigned long n) if ((long) n < 0 && c == 'd') { - n = (unsigned) (-((long) n)); + n = (unsigned long) (-((long) n)); *str++ = '-'; }