utils.c File Reference

utility functions More...

#include <stdio.h>
#include <sys/types.h>
#include <unistd.h>
#include <errno.h>
#include <stdlib.h>
#include <string.h>
#include <signal.h>
#include <dirent.h>
#include <fcntl.h>
#include "debug.h"
#include "config.h"
#include "utils.h"
#include "pcscd.h"
#include "sys_generic.h"

Include dependency graph for utils.c:

Go to the source code of this file.

Functions

pid_t GetDaemonPid (void)
int SendHotplugSignal (void)
int StatSynchronize (struct pubReaderStatesList *readerState)
 Sends an asynchronous event to any waiting client.


Detailed Description

utility functions

Definition in file utils.c.


Function Documentation

int StatSynchronize ( struct pubReaderStatesList readerState  ) 

Sends an asynchronous event to any waiting client.

Just write 1 byte to any fifo in PCSCLITE_EVENTS_DIR and remove the file

This function must be secured since the files are created by the library or any non privileged process. We must not follow symlinks for example

Definition at line 86 of file utils.c.

References SYS_CloseFile(), SYS_GetPageSize(), SYS_MMapSynchronize(), and SYS_OpenFile().

Referenced by SCardConnect(), SCardDisconnect(), and SCardReconnect().

Here is the call graph for this function:


Generated on Sat Sep 6 07:44:40 2008 for pcsc-lite by  doxygen 1.5.6