From 7f7ea759ebdc854beb0468b410f7d2382f291a4f Mon Sep 17 00:00:00 2001 From: Uwe Hermann Date: Wed, 1 Feb 2012 23:14:29 +0100 Subject: srd: Properly use append() for appending to lists. This is not only the canonical way to do it, it's also quite a bit faster and less memory-intensive than using '+='. --- decoders/ebr30a_i2c_demux/ebr30a_i2c_demux.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'decoders/ebr30a_i2c_demux') diff --git a/decoders/ebr30a_i2c_demux/ebr30a_i2c_demux.py b/decoders/ebr30a_i2c_demux/ebr30a_i2c_demux.py index 1a52fb8..50a1dbe 100644 --- a/decoders/ebr30a_i2c_demux/ebr30a_i2c_demux.py +++ b/decoders/ebr30a_i2c_demux/ebr30a_i2c_demux.py @@ -67,7 +67,7 @@ class Decoder(srd.Decoder): cmd, databyte, ack_bit = data # Add the I2C packet to our local cache. - self.packets += [[ss, es, data]] + self.packets.append([ss, es, data]) if cmd in ('ADDRESS READ', 'ADDRESS WRITE'): # print(hex(databyte)) -- cgit v1.2.3-70-g09d2