From e28f7aee3b96afeb543e0c3c29e3950ddd61a490 Mon Sep 17 00:00:00 2001 From: Uwe Hermann Date: Tue, 8 Jul 2014 21:21:03 +0200 Subject: All PDs: Drop unneeded exceptions. In all current PDs it is not necessary to raise an exception upon invalid states (of the PD's state machine), since we can guarantee that no such invalid state can ever be reached in these PDs. --- decoders/uart/pd.py | 2 -- 1 file changed, 2 deletions(-) (limited to 'decoders/uart') diff --git a/decoders/uart/pd.py b/decoders/uart/pd.py index ae99874..ff8a516 100644 --- a/decoders/uart/pd.py +++ b/decoders/uart/pd.py @@ -360,8 +360,6 @@ class Decoder(srd.Decoder): self.get_parity_bit(rxtx, signal) elif self.state[rxtx] == 'GET STOP BITS': self.get_stop_bits(rxtx, signal) - else: - raise Exception('Invalid state: %s' % self.state[rxtx]) # Save current RX/TX values for the next round. self.oldbit[rxtx] = signal -- cgit v1.2.3-70-g09d2