[MERGED] pysim[master]: pySim-prog: Replace magic numbers with a readable EF file name.

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/.

Alexander Chemeris gerrit-no-reply at lists.osmocom.org
Sat Jan 13 15:25:54 UTC 2018


Alexander Chemeris has submitted this change and it was merged.

Change subject: pySim-prog: Replace magic numbers with a readable EF file name.
......................................................................


pySim-prog: Replace magic numbers with a readable EF file name.

Change-Id: Ibda7d5a4132971e884f6d760baf20cd33025a2af
---
M pySim-prog.py
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Vadim Yanitskiy: Looks good to me, but someone else must approve
  Alexander Chemeris: Verified
  Harald Welte: Looks good to me, approved



diff --git a/pySim-prog.py b/pySim-prog.py
index 2177d8c..44ca1fd 100755
--- a/pySim-prog.py
+++ b/pySim-prog.py
@@ -618,7 +618,7 @@
 					# Connect transport
 					print "Insert card now (or CTRL-C to cancel)"
 					sl.wait_for_card(newcardonly=not first)
-				(res,_) = scc.read_binary(['3f00', '7f20', '6f07'])
+				(res,_) = scc.read_binary(EF['IMSI'])
 				imsi = swap_nibbles(res)[3:]
 			else:
 				imsi = opts.imsi

-- 
To view, visit https://gerrit.osmocom.org/5720
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ibda7d5a4132971e884f6d760baf20cd33025a2af
Gerrit-PatchSet: 2
Gerrit-Project: pysim
Gerrit-Branch: master
Gerrit-Owner: Alexander Chemeris <Alexander.Chemeris at gmail.com>
Gerrit-Reviewer: Alexander Chemeris <Alexander.Chemeris at gmail.com>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Vadim Yanitskiy <axilirator at gmail.com>



More information about the gerrit-log mailing list