Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 108797
Collapse All | Expand All

(-)pycsc-0.0.3_/pycsc.c (-10 / +10 lines)
Lines 23-29 Link Here
23
#endif
23
#endif
24
24
25
/* Internal tool */
25
/* Internal tool */
26
static LONG getReaderList(SCARDCONTEXT hContext, LPSTR* pmszReaders, 
26
static LONG getReaderList(SCARDCONTEXT hContext, LPTSTR* pmszReaders, 
27
                          DWORD *pdwReaders);
27
                          DWORD *pdwReaders);
28
28
29
#ifdef _WINDOWS_
29
#ifdef _WINDOWS_
Lines 256-269 Link Here
256
  BYTE  pbAtr[MAX_ATR_SIZE];
256
  BYTE  pbAtr[MAX_ATR_SIZE];
257
  DWORD dwAtrLen, dwProt=0, dwState=0;
257
  DWORD dwAtrLen, dwProt=0, dwState=0;
258
  DWORD dwReaderLen;
258
  DWORD dwReaderLen;
259
  LPSTR pcReaders;
259
  LPTSTR pcReaders;
260
  LONG  rv;
260
  LONG  rv;
261
  PyObject *ret_value;
261
  PyObject *ret_value;
262
262
263
  dwReaderLen = 10000;
263
  dwReaderLen = 10000;
264
  dwAtrLen = 0;
264
  dwAtrLen = 0;
265
  /* Dry run to get the length of the reader name */ 
265
  /* Dry run to get the length of the reader name */ 
266
  rv = SCardStatus( object->hCard, (LPSTR) NULL, &dwReaderLen, 
266
  rv = SCardStatus( object->hCard, (LPTSTR) NULL, &dwReaderLen, 
267
            &dwState, &dwProt, NULL, &dwAtrLen );
267
            &dwState, &dwProt, NULL, &dwAtrLen );
268
268
269
  if ( rv != SCARD_S_SUCCESS )
269
  if ( rv != SCARD_S_SUCCESS )
Lines 499-506 Link Here
499
static PyObject * pycscobject_pycsc(PyObject *self, PyObject * args, PyObject *keywds)
499
static PyObject * pycscobject_pycsc(PyObject *self, PyObject * args, PyObject *keywds)
500
{
500
{
501
  /* No reader name in args, connect to the first reader */
501
  /* No reader name in args, connect to the first reader */
502
  LPSTR mszReaders = NULL;
502
  LPTSTR mszReaders = NULL;
503
  LPSTR szRequestedReader = "";
503
  LPTSTR szRequestedReader = "";
504
  DWORD dwReaders;
504
  DWORD dwReaders;
505
  DWORD dwMode = SCARD_SHARE_SHARED;
505
  DWORD dwMode = SCARD_SHARE_SHARED;
506
  DWORD eProtocol;   /* effective protocol */
506
  DWORD eProtocol;   /* effective protocol */
Lines 611-618 Link Here
611
static PyObject * pycscobject_listReader(PyObject *self, PyObject * args)
611
static PyObject * pycscobject_listReader(PyObject *self, PyObject * args)
612
{
612
{
613
  SCARDCONTEXT  hContext;
613
  SCARDCONTEXT  hContext;
614
  LPSTR mszReaders = NULL;
614
  LPTSTR mszReaders = NULL;
615
  LPSTR mszReadersScan;
615
  LPTSTR mszReadersScan;
616
  DWORD dwReaders;
616
  DWORD dwReaders;
617
  LONG rv;
617
  LONG rv;
618
618
Lines 941-950 Link Here
941
}
941
}
942
942
943
/* Internal tool */
943
/* Internal tool */
944
static LONG getReaderList(SCARDCONTEXT hContext, LPSTR* pmszReaders, DWORD *pdwReaders)
944
static LONG getReaderList(SCARDCONTEXT hContext, LPTSTR* pmszReaders, DWORD *pdwReaders)
945
{
945
{
946
  LPCSTR mszGroups = 0;
946
  LPCTSTR mszGroups = 0;
947
  LPSTR mszReaders = NULL;
947
  LPTSTR mszReaders = NULL;
948
  LONG  dwReaders;
948
  LONG  dwReaders;
949
  LONG rv;
949
  LONG rv;
950
950
(-)pycsc-0.0.3_/setup.py (-1 / +1 lines)
Lines 31-37 Link Here
31
         include = []
31
         include = []
32
    else:
32
    else:
33
         libs = ["pcsclite"]
33
         libs = ["pcsclite"]
34
         include = ["/usr/include/pcsc"]
34
         include = ["/usr/include/PCSC"]
35
35
36
36
37
setup(name="pycsc", version="0.3",
37
setup(name="pycsc", version="0.3",

Return to bug 108797