diff --git a/channels/smartcard/client/smartcard_operations.c b/channels/smartcard/client/smartcard_operations.c index ac6c270c9..d054c8621 100644 --- a/channels/smartcard/client/smartcard_operations.c +++ b/channels/smartcard/client/smartcard_operations.c @@ -763,7 +763,6 @@ static UINT32 handle_ListReaders(SMARTCARD_DEVICE* smartcard, IRP* irp, BOOL wid if (status) goto finish; - /* Read RedirScardcontextRef */ status = handle_RedirContextRef(smartcard, irp, redirect, &hContext); if (status) diff --git a/channels/smartcard/client/smartcard_pack.c b/channels/smartcard/client/smartcard_pack.c index ee4fe0458..255024cdc 100644 --- a/channels/smartcard/client/smartcard_pack.c +++ b/channels/smartcard/client/smartcard_pack.c @@ -21,6 +21,9 @@ #include "config.h" #endif +#include +#include + #include "smartcard_pack.h" UINT32 smartcard_unpack_establish_context_call(SMARTCARD_DEVICE* smartcard, wStream* s, EstablishContext_Call* call) @@ -55,16 +58,8 @@ UINT32 smartcard_unpack_list_readers_call(SMARTCARD_DEVICE* smartcard, wStream* return SCARD_F_INTERNAL_ERROR; } - if (call->cBytes) - { - call->mszGroups = malloc(call->cBytes); - Stream_Read(s, call->mszGroups, call->cBytes); /* mszGroups */ - } - else - { - call->mszGroups = NULL; - Stream_Seek(s, 4); /* mszGroups */ - } + call->mszGroups = NULL; + Stream_Seek(s, 4); /* mszGroupsPtr (4 bytes) */ Stream_Read_UINT32(s, call->fmszReadersIsNULL); /* fmszReadersIsNULL (4 bytes) */ Stream_Read_UINT32(s, call->cchReaders); /* cchReaders (4 bytes) */ @@ -76,5 +71,7 @@ UINT32 smartcard_unpack_list_readers_call(SMARTCARD_DEVICE* smartcard, wStream* return SCARD_F_INTERNAL_ERROR; } + /* FIXME: complete parsing */ + return SCARD_S_SUCCESS; }