Change in pysim[master]: filesystem: CardProfile: initialize empty sw table as empty dict

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

dexter gerrit-no-reply at lists.osmocom.org
Wed Nov 10 16:56:40 UTC 2021


dexter has uploaded this change for review. ( https://gerrit.osmocom.org/c/pysim/+/26202 )


Change subject: filesystem: CardProfile: initialize empty sw table as empty dict
......................................................................

filesystem: CardProfile: initialize empty sw table as empty dict

The table that holds the status word descriptions is initialized as an
empty list '[]'. This is not correct since the interpret_sw method
processes this data as dictionary, so lets initialize the sw member with
an empty dict '{}' when not status word description is given.

Change-Id: I3cae83f0f6ab274546991ecd14425f094b2816b2
Related: OS#5274
---
M pySim/filesystem.py
1 file changed, 1 insertion(+), 1 deletion(-)



  git pull ssh://gerrit.osmocom.org:29418/pysim refs/changes/02/26202/1

diff --git a/pySim/filesystem.py b/pySim/filesystem.py
index 6e5a359..79c997c 100644
--- a/pySim/filesystem.py
+++ b/pySim/filesystem.py
@@ -1461,7 +1461,7 @@
         self.name = name
         self.desc = kw.get("desc", None)
         self.files_in_mf = kw.get("files_in_mf", [])
-        self.sw = kw.get("sw", [])
+        self.sw = kw.get("sw", {})
         self.applications = kw.get("applications", [])
         self.shell_cmdsets = kw.get("shell_cmdsets", [])
         self.cla = kw.get("cla", "00")

-- 
To view, visit https://gerrit.osmocom.org/c/pysim/+/26202
To unsubscribe, or for help writing mail filters, visit https://gerrit.osmocom.org/settings

Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Change-Id: I3cae83f0f6ab274546991ecd14425f094b2816b2
Gerrit-Change-Number: 26202
Gerrit-PatchSet: 1
Gerrit-Owner: dexter <pmaier at sysmocom.de>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osmocom.org/pipermail/gerrit-log/attachments/20211110/027c72ca/attachment.htm>


More information about the gerrit-log mailing list