channels/smartcard: start splitting decoding from calling

This commit is contained in:
Marc-André Moreau 2014-05-12 14:13:57 -04:00
parent fc39f6bc8d
commit 8a940ad778
3 changed files with 683 additions and 387 deletions

View File

@ -158,6 +158,8 @@ static void smartcard_init(DEVICE* device)
* Call SCardCancel on existing contexts, unblocking all outstanding IRPs.
*/
printf("rgSCardContextList: %d\n", ListDictionary_Count(smartcard->rgSCardContextList));
if (ListDictionary_Count(smartcard->rgSCardContextList) > 0)
{
pKeys = NULL;
@ -174,7 +176,6 @@ static void smartcard_init(DEVICE* device)
if (SCardIsValidContext(hContext))
{
printf("SCardCancel: 0x%08X\n", hContext);
SCardCancel(hContext);
}
}
@ -202,7 +203,6 @@ static void smartcard_init(DEVICE* device)
if (SCardIsValidContext(hContext))
{
printf("SCardReleaseContext: 0x%08X\n", hContext);
SCardReleaseContext(hContext);
}
}

File diff suppressed because it is too large Load Diff

View File

@ -24,8 +24,6 @@
#include <winpr/stream.h>
#include <winpr/smartcard.h>
#include "smartcard_main.h"
/* interface type_scard_pack */
/* [unique][version][uuid] */
@ -429,6 +427,8 @@ typedef struct _WriteCacheW_Call
#define SMARTCARD_COMMON_TYPE_HEADER_LENGTH 8
#define SMARTCARD_PRIVATE_TYPE_HEADER_LENGTH 8
#include "smartcard_main.h"
UINT32 smartcard_pack_write_size_align(SMARTCARD_DEVICE* smartcard, wStream* s, UINT32 size, UINT32 alignment);
UINT32 smartcard_unpack_read_size_align(SMARTCARD_DEVICE* smartcard, wStream* s, UINT32 size, UINT32 alignment);