2.2.2.4 ListReaders_Call

The ListReaders_Call structure contains the parameters for the List Readers call (for more information, see sections 3.1.4.7 and 3.1.4.8).

 typedef struct _ListReaders_Call {
   REDIR_SCARDCONTEXT Context;
   [range(0, 65536)] unsigned long cBytes;
   [unique] [size_is(cBytes)] const byte *mszGroups;
   long fmszReadersIsNULL;
   unsigned long cchReaders;
 } ListReaders_Call;

Context: A valid context, as specified in section 2.2.1.1.

cBytes: The length, in bytes, of reader groups specified in mszGroups.

mszGroups: The names of the reader groups defined in the system. Reader groups not present on the protocol server MUST be ignored. The value of this is dependent on the context (IOCTL) that it is used.

Value

Meaning

SCARD_IOCTL_LISTREADERSA

0x00090028

ASCII multistring

SCARD_IOCTL_LISTREADERSW

0x0009002C

Unicode multistring

fmszReadersIsNULL: A Boolean value specifying whether the caller wants to retrieve the length of the data. Set to FALSE (0x00000000) to allow the data to be returned. Set to TRUE (0x00000001), and only the length of the data will be returned.

cchReaders: The length of the string buffer specified by the caller. If cchReaders is set to SCARD_AUTOALLOCATE with a value of 0xFFFFFFFF, a string of any length can be returned. Otherwise, the returned string MUST NOT exceed cchReaders characters in length, including any NULL characters. When the string to be returned exceeds cchReaders characters in length, including any null characters, ListReaders_Return.ReturnCode MUST be set to SCARD_E_INSUFFICIENT_BUFFER (0x80100008). The cchReaders field MUST be ignored if fmszReadersIsNULL is set to TRUE (0x00000001). Also, if fmszReadersIsNULL is set to FALSE (0x00000000) but cchReaders is set to 0x00000000, then the call MUST succeed, ListReaders_Return.cBytes MUST be set to the length of the data in bytes, and ListReaders_Return.msz MUST be set to NULL.