mirror of
https://gitea.osmocom.org/sim-card/pysim.git
synced 2026-03-16 18:38:32 +03:00
Don't try to parse result if select_file() failed
Change-Id: I25b859374e33654e58d07061926bf8529eab87f3
This commit is contained in:
@@ -109,6 +109,8 @@ class SimCardCommands(object):
|
||||
if not hasattr(type(ef), '__iter__'):
|
||||
ef = [ef]
|
||||
r = self.select_file(ef)
|
||||
if len(r[-1]) == 0:
|
||||
return (None, None)
|
||||
if length is None:
|
||||
length = self.__len(r) - offset
|
||||
pdu = self.cla_byte + 'b0%04x%02x' % (offset, (min(256, length) & 0xff))
|
||||
|
||||
Reference in New Issue
Block a user