dc's stack breaks when doing modulo-0

Markus Gothe nietzsche at lysator.liu.se
Wed May 8 17:48:41 UTC 2019


It's the small one. The bug is but in git-master and at least in 1.22.x

//M

Sent from my BlackBerry — the most secure mobile device


	  Original Message  



From: gavin.d.howard at gmail.com
Sent: 8 May 2019 19:35
To: busybox at busybox.net
Subject: Re: dc's stack breaks when doing modulo-0


> dc -e '4 0 % p' mess up the stack so bad that my MIPS kernel traps it and reboots.
>
> I think we should, like the regular dc, check for 0 as a divider when doing modulo.
>
> //M

Markus,

Was this the full dc or the small dc? As far as I know (I am the
original author of the full dc), the full dc does, in fact, return an
error and not trap.

Gavin Howard
_______________________________________________
busybox mailing list
busybox at busybox.net
http://lists.busybox.net/mailman/listinfo/busybox


More information about the busybox mailing list