From e80c647b22d9ecdf2eae2e2078e69db3793c5eb1 Mon Sep 17 00:00:00 2001 From: frankmorgner Date: Wed, 10 Mar 2010 09:14:38 +0000 Subject: [PATCH] bugfix git-svn-id: https://vsmartcard.svn.sourceforge.net/svnroot/vsmartcard@47 96b47cad-a561-4643-ad3b-153ac7d7599c --- ccid/apdu.c | 11 +++++++++++ ccid/apdu.h | 6 +++--- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/ccid/apdu.c b/ccid/apdu.c index 87988ae..e3f4368 100644 --- a/ccid/apdu.c +++ b/ccid/apdu.c @@ -21,6 +21,8 @@ #include "apdu.h" #include #include +#include + /*********************************************************************/ /* higher level APDU transfer handling functions */ @@ -48,6 +50,15 @@ */ +#ifndef _WIN32 +#include +#define msleep(t) usleep((t) * 1000) +#else +#define msleep(t) Sleep(t) +#define sleep(t) Sleep((t) * 1000) +#endif + + /** Tries to determine the APDU type (short or extended) of the supplied * APDU if one of the SC_APDU_CASE_? types is used. * @param apdu APDU object diff --git a/ccid/apdu.h b/ccid/apdu.h index 3360574..c81f692 100644 --- a/ccid/apdu.h +++ b/ccid/apdu.h @@ -1,11 +1,11 @@ -#ifndef _PACE_H -#define _PACE_H +#ifndef _APDU_H +#define _APDU_H #ifdef __cplusplus extern "C" { #endif -#include +#include /** Sends a APDU to the card * @param card sc_card_t object to which the APDU should be send