From ee6ab9193971e4e05307cc7ce63f898589ee1d58 Mon Sep 17 00:00:00 2001 From: AJR Date: Sat, 22 Oct 2022 11:23:33 -0400 Subject: 6840ptm.cpp: Fix unsigned comparison --- src/devices/machine/6840ptm.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/devices/machine/6840ptm.cpp b/src/devices/machine/6840ptm.cpp index f99652db339..4d2a146f0e9 100644 --- a/src/devices/machine/6840ptm.cpp +++ b/src/devices/machine/6840ptm.cpp @@ -182,7 +182,7 @@ void ptm6840_device::deduct_from_counter(int idx) lsb = (m_latch[idx] & 0xff) + 1; msb--; - if (msb < 0) + if (msb == 0xffff) { // If MSB is less than zero, we've timed out, no need to manually reload timed_out = true; -- cgit v1.2.3