error.c File Reference

This handles pcsc_stringify_error(). More...

#include <stdio.h>
#include <sys/types.h>
#include "misc.h"
#include "pcsclite.h"
#include "strlcpycat.h"

Go to the source code of this file.

Functions

PCSC_API char * pcsc_stringify_error (long pcscError)
 This function return a human readable text for the given PC/SC error code.


Detailed Description

This handles pcsc_stringify_error().

Definition in file error.c.


Function Documentation

PCSC_API char* pcsc_stringify_error ( long  pcscError  ) 

This function return a human readable text for the given PC/SC error code.

Parameters:
[in] pcscError Error code to be translated to text.
Returns:
Text representing de error code passed.
Test:
 SCARDCONTEXT hContext;
 LONG rv;
 rv = SCardEstablishContext(SCARD\_SCOPE\_SYSTEM, NULL, NULL, &hContext);
 if (rv != SCARD_S_SUCCESS)
     printf("SCardReleaseContext: %s (0x%lX)\n",
         pcsc_stringify_error(rv), rv);

Definition at line 45 of file error.c.

References SCARD_E_CANCELLED, SCARD_E_CANT_DISPOSE, SCARD_E_CARD_UNSUPPORTED, SCARD_E_DUPLICATE_READER, SCARD_E_INSUFFICIENT_BUFFER, SCARD_E_INVALID_ATR, SCARD_E_INVALID_HANDLE, SCARD_E_INVALID_PARAMETER, SCARD_E_INVALID_TARGET, SCARD_E_INVALID_VALUE, SCARD_E_NO_MEMORY, SCARD_E_NO_SERVICE, SCARD_E_NO_SMARTCARD, SCARD_E_NOT_READY, SCARD_E_NOT_TRANSACTED, SCARD_E_PCI_TOO_SMALL, SCARD_E_PROTO_MISMATCH, SCARD_E_READER_UNAVAILABLE, SCARD_E_READER_UNSUPPORTED, SCARD_E_SERVICE_STOPPED, SCARD_E_SHARING_VIOLATION, SCARD_E_SYSTEM_CANCELLED, SCARD_E_TIMEOUT, SCARD_E_UNKNOWN_CARD, SCARD_E_UNKNOWN_READER, SCARD_E_UNSUPPORTED_FEATURE, SCARD_F_COMM_ERROR, SCARD_F_INTERNAL_ERROR, SCARD_F_UNKNOWN_ERROR, SCARD_F_WAITED_TOO_LONG, SCARD_S_SUCCESS, SCARD_W_INSERTED_CARD, SCARD_W_REMOVED_CARD, SCARD_W_RESET_CARD, SCARD_W_UNPOWERED_CARD, SCARD_W_UNRESPONSIVE_CARD, and SCARD_W_UNSUPPORTED_CARD.

Referenced by main(), and test_rv().


Generated on Mon Aug 27 13:45:37 2007 for pcsc-lite by  doxygen 1.5.2