mirror of
https://github.com/irmen/prog8.git
synced 2024-12-25 08:29:25 +00:00
avoid division by zero if host fs hyperload is used which loads instantly
This commit is contained in:
parent
79d0fb0b52
commit
7b59bc8d12
@ -10,6 +10,10 @@ main {
|
||||
const ubyte REPEATS = 2
|
||||
|
||||
sub print_speed(uword jiffies) {
|
||||
if jiffies==0 {
|
||||
txt.print("\n 0 jiffies measured, speed is extremely high\n")
|
||||
return
|
||||
}
|
||||
float speed = 65536.0 * REPEATS / (jiffies as float / 60.0)
|
||||
txt.nl()
|
||||
txt.print_uw(jiffies)
|
||||
|
Loading…
Reference in New Issue
Block a user