* grub-core/term/tparm.c (tparam_internal): Use unsigned divisions.
This commit is contained in:
parent
ef28ee8bc1
commit
f649a6a8fd
2 changed files with 8 additions and 2 deletions
|
@ -1,3 +1,7 @@
|
||||||
|
2013-11-12 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
|
* grub-core/term/tparm.c (tparam_internal): Use unsigned divisions.
|
||||||
|
|
||||||
2013-11-12 Vladimir Serbinenko <phcoder@gmail.com>
|
2013-11-12 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
Add missing includes of loader.h.
|
Add missing includes of loader.h.
|
||||||
|
|
|
@ -614,13 +614,15 @@ tparam_internal(const char *string, va_list ap)
|
||||||
case '/':
|
case '/':
|
||||||
y = npop();
|
y = npop();
|
||||||
x = npop();
|
x = npop();
|
||||||
npush(y ? (x / y) : 0);
|
/* GRUB has no signed divisions. */
|
||||||
|
npush(y ? ((unsigned)x / (unsigned)y) : 0);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'm':
|
case 'm':
|
||||||
y = npop();
|
y = npop();
|
||||||
x = npop();
|
x = npop();
|
||||||
npush(y ? (x % y) : 0);
|
/* GRUB has no signed divisions. */
|
||||||
|
npush(y ? ((unsigned)x % (unsigned)y) : 0);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case 'A':
|
case 'A':
|
||||||
|
|
Loading…
Reference in a new issue