Logo Search packages:      
Sourcecode: pcsc-lite version File versions

LONG IFDSetCapabilities ( PREADER_CONTEXT  rContext,
DWORD  dwTag,
DWORD  dwLength,
PUCHAR  pucValue 
)

Set capabilities in the reader.

Definition at line 233 of file ifdwrapper.c.

Referenced by IFDPowerICC(), IFDSetPTS(), IFDStatusICC(), IFDTransmit(), and SCardSetAttrib().

{
      RESPONSECODE rv = IFD_SUCCESS;

#ifndef PCSCLITE_STATIC_DRIVER
      RESPONSECODE(*IFD_set_capabilities) (DWORD, PUCHAR) = NULL;
      RESPONSECODE(*IFDH_set_capabilities) (DWORD, DWORD, DWORD, PUCHAR) = NULL;

      if (rContext->dwVersion == IFD_HVERSION_1_0)
            IFD_set_capabilities = rContext->psFunctions.psFunctions_v1.pvfSetCapabilities;
      else
            IFDH_set_capabilities = rContext->psFunctions.psFunctions_v2.pvfSetCapabilities;
#endif

      /*
       * Let the calling function lock this otherwise a deadlock will
       * result
       */

#ifndef PCSCLITE_STATIC_DRIVER
      if (rContext->dwVersion == IFD_HVERSION_1_0)
            rv = (*IFD_set_capabilities) (dwTag, pucValue);
      else
            rv = (*IFDH_set_capabilities) (rContext->dwSlot, dwTag,
                  dwLength, pucValue);
#else
      if (rContext->dwVersion == IFD_HVERSION_1_0)
            rv = IFD_Set_Capabilities(dwTag, pucValue);
      else
            rv = IFDHSetCapabilities(rContext->dwSlot, dwTag, dwLength,
                  pucValue);
#endif

      return rv;
}


Generated by  Doxygen 1.6.0   Back to index