pcsc-lite
1.8.2
|
00001 /* 00002 * MUSCLE SmartCard Development ( http://www.linuxnet.com ) 00003 * 00004 * Copyright (C) 2006-2009 00005 * Ludovic Rousseau <ludovic.rousseau@free.fr> 00006 * 00007 * $Id: utils.h 5196 2010-08-27 12:52:27Z rousseau $ 00008 */ 00009 00010 #ifndef __utils_h__ 00011 #define __utils_h__ 00012 00013 #include <sys/types.h> 00014 #include "wintypes.h" 00015 #include "readerfactory.h" 00016 00017 #define PID_ASCII_SIZE 11 00018 pid_t GetDaemonPid(void); 00019 int SendHotplugSignal(void); 00020 00021 /* defined in winscard_clnt.c */ 00022 LONG SCardCheckDaemonAvailability(void); 00023 00024 int CheckForOpenCT(void); 00025 00026 long int time_sub(struct timeval *a, struct timeval *b); 00027 00028 /* thread attributes */ 00029 #define THREAD_ATTR_DEFAULT 0 00030 #define THREAD_ATTR_DETACHED 1 00031 00032 #define PCSCLITE_THREAD_FUNCTION(f) void *(*f)(void *) 00033 00034 int ThreadCreate(pthread_t *, int, PCSCLITE_THREAD_FUNCTION( ), 00035 /*@null@*/ LPVOID); 00036 00037 #endif 00038