cid#360694 silence Division or modulo by float zero

Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: Ifac9d92f95e131f2888bef6a74435b3d6a8df829
pull/8791/head
Caolán McNamara 2024-04-13 16:14:42 +01:00 committed by Miklos Vajna
parent 7f4fd7f556
commit c4a6b37460
1 changed files with 2 additions and 0 deletions

View File

@ -57,6 +57,8 @@ public:
std::cout << "took: " <<
std::chrono::duration_cast<std::chrono::milliseconds>(end - start).count() << "ms - ";
assert(deltas && "div by zero otherwise");
std::cout << "time/rle: " <<
(1.0*std::chrono::duration_cast<std::chrono::microseconds>(end - start).count())/deltas << "us\n";
}