diff options
author | Gerhard Sittig <gerhard.sittig@gmx.net> | 2018-08-01 18:35:57 +0200 |
---|---|---|
committer | Uwe Hermann <uwe@hermann-uwe.de> | 2018-08-11 22:58:45 +0200 |
commit | 389d21d222a503b9f5f43404ced4b10813008b3a (patch) | |
tree | d975b588fc0d28b11191d4aff98a24e0bf60d677 | |
parent | 5166b0317835b35d810506f36e1a957e58109515 (diff) | |
download | libsigrokdecode-389d21d222a503b9f5f43404ced4b10813008b3a.tar.gz libsigrokdecode-389d21d222a503b9f5f43404ced4b10813008b3a.zip |
mdio: accept MDIO READ without previous ADDRESS command
Fix a Python string formatting issue, where the format string disagreed
with the argument list. A READ command could unexpectedly terminate the
decoder instance when there was no previous ADDRESS command.
This fixes bug #1258.
-rw-r--r-- | decoders/mdio/pd.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/decoders/mdio/pd.py b/decoders/mdio/pd.py index 9ea3a27..2522912 100644 --- a/decoders/mdio/pd.py +++ b/decoders/mdio/pd.py @@ -95,7 +95,7 @@ class Decoder(srd.Decoder): if self.clause45 and self.clause45_addr != -1: decoded_min += str.format('ADDR: %04X ' % self.clause45_addr) elif self.clause45: - decoded_min += str.format('ADDR: UKWN ' % self.clause45_addr) + decoded_min += str.format('ADDR: UKWN ') if self.clause45 and self.opcode > 1 \ or (not self.clause45 and self.opcode): |