From 7d2f9b4da5e2364b5b8dec9b95728a5b8f57f5a9 Mon Sep 17 00:00:00 2001 From: hploetz Date: Fri, 8 Jun 2007 00:09:55 +0000 Subject: [PATCH] API change: let read_binary_file return two values git-svn-id: svn+ssh://localhost/home/henryk/svn/cyberflex-shell/trunk@220 f711b948-2313-0410-aaa9-d29f33439f0b --- cards/building_blocks.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cards/building_blocks.py b/cards/building_blocks.py index a6fe5a4..070ae67 100644 --- a/cards/building_blocks.py +++ b/cards/building_blocks.py @@ -122,11 +122,11 @@ class Card_with_read_binary: if had_one: ## If there was at least one successful pass, ignore any error SW. It probably only means "end of file" self.sw_changed = False - return contents + return contents, result.sw def cmd_cat(self): "Print a hexdump of the currently selected file (e.g. consecutive READ BINARY)" - contents = self.read_binary_file() + contents, sw = self.read_binary_file() self.last_result = R_APDU(contents + self.last_sw) print utils.hexdump(contents,linelen=self.HEXDUMP_LINELEN)