diff options
author | Werner Koch <[email protected]> | 2004-10-14 09:12:36 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2004-10-14 09:12:36 +0000 |
commit | e1f3dc1c77fe155b05f106c1711bce1e5b62c9b6 (patch) | |
tree | 497496e6d62e3356d944ba5ca84fb439225ba47b /scd/iso7816.c | |
parent | 2004-10-08 Moritz Schulte <[email protected]> (diff) | |
download | gnupg-e1f3dc1c77fe155b05f106c1711bce1e5b62c9b6.tar.gz gnupg-e1f3dc1c77fe155b05f106c1711bce1e5b62c9b6.zip |
Added ID keywords because these files are often used in other packages.
Diffstat (limited to '')
-rw-r--r-- | scd/iso7816.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/scd/iso7816.c b/scd/iso7816.c index cbb314eb2..4861466c1 100644 --- a/scd/iso7816.c +++ b/scd/iso7816.c @@ -16,6 +16,8 @@ * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA + * + * $Id$ */ #include <config.h> @@ -103,6 +105,17 @@ map_sw (int sw) return gpg_error (ec); } +/* Map a status word from the APDU layer to a gpg-error code. */ +gpg_error_t +iso7816_map_sw (int sw) +{ + /* All APDU functions should return 0x9000 on success but for + historical reasons of the implementation some return 0 to + indicate success. We allow for that here. */ + return sw? map_sw (sw) : 0; +} + + /* This function is specialized version of the SELECT FILE command. SLOT is the card and reader as created for example by apdu_open_reader (), AID is a buffer of size AIDLEN holding the |