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

static LONG SCardGetContextIndiceTH ( SCARDCONTEXT  hContext  )  [static]

Get the index from the Application Context vector psContextMap for the passed context.

This functions is not thread-safe and should not be called. Instead, call the function SCardGetContextIndice().

Parameters:
[in] hContext Application Context whose index will be find.
Returns:
Index corresponding to the Application Context or -1 if it is not found.

Definition at line 2842 of file winscard_clnt.c.

References psContextMap.

Referenced by SCardGetContextIndice(), and SCardRemoveContext().

{
      int i;

      /*
       * Find this context and return it's spot in the array
       */
      for (i = 0; i < PCSCLITE_MAX_APPLICATION_CONTEXTS; i++)
      {
            if ((hContext == psContextMap[i].hContext) && (hContext != 0))
                  return i;
      }

      return -1;
}


Generated by  Doxygen 1.6.0   Back to index