Polls fanotify events.
More...
#include <FanotifyPolling.h>
|
static int | markMount (int fd, const char *mount) |
| Marks a mount for polling fanotify events. More...
|
|
static int | unmarkMount (int fd, const char *mount) |
| Removes a mount from polling fanotify events. More...
|
|
|
static void * | run (void *) |
| Thread listening to fanotify events. More...
|
|
static void * | scanFile (void *workitem) |
| Scans a file. More...
|
|
Polls fanotify events.
Definition at line 43 of file FanotifyPolling.h.
typedef void(* FanotifyPolling::skyld_pollfanotifycallbackptr)(const int fd, const void *buf, int len) |
|
private |
Enumerator |
---|
INITIAL |
|
RUNNING |
|
STOPPING |
|
FAILURE |
|
SUCCESS |
|
Definition at line 46 of file FanotifyPolling.h.
Starts polling fanotify events.
- Parameters
-
- Returns
- success
Definition at line 333 of file FanotifyPolling.cc.
FanotifyPolling::~FanotifyPolling |
( |
| ) |
|
int FanotifyPolling::exclude |
( |
const int |
fd | ) |
|
|
private |
Check if file is in exclude path.
- Parameters
-
- Returns
- 1 if in exclude path.
Definition at line 138 of file FanotifyPolling.cc.
int FanotifyPolling::fanotifyClose |
( |
| ) |
|
|
private |
int FanotifyPolling::fanotifyOpen |
( |
| ) |
|
|
private |
Opens fanotify file descriptor.
- Returns
- success = 0;
Properties of event file descriptors.
Behavior of the fanotify file descriptor.
Definition at line 501 of file FanotifyPolling.cc.
void FanotifyPolling::handleFanotifyEvent |
( |
const struct fanotify_event_metadata * |
metadata | ) |
|
|
private |
Handle fanotify events.
- Parameters
-
buf | buffer with events |
len | length of the buffer |
Definition at line 222 of file FanotifyPolling.cc.
void FanotifyPolling::handleFanotifyEvents |
( |
const void * |
buf, |
|
|
int |
len |
|
) |
| |
|
private |
Handle fanotify events.
- Parameters
-
buf | buffer with events |
len | length of the buffer |
Definition at line 312 of file FanotifyPolling.cc.
int FanotifyPolling::markMount |
( |
int |
fd, |
|
|
const char * |
mount |
|
) |
| |
|
static |
Marks a mount for polling fanotify events.
- Parameters
-
- Returns
- success
Definition at line 551 of file FanotifyPolling.cc.
void * FanotifyPolling::run |
( |
void * |
obj | ) |
|
|
staticprivate |
Thread listening to fanotify events.
- Parameters
-
ccbptr | pointer to callback routine |
- Returns
- NULL
Fanotify polling object.
File descriptor.
number of file descriptors
Buffer.
Definition at line 50 of file FanotifyPolling.cc.
void * FanotifyPolling::scanFile |
( |
void * |
workitem | ) |
|
|
staticprivate |
int FanotifyPolling::unmarkMount |
( |
int |
fd, |
|
|
const char * |
mount |
|
) |
| |
|
static |
Removes a mount from polling fanotify events.
- Parameters
-
- Returns
- success
Definition at line 578 of file FanotifyPolling.cc.
int FanotifyPolling::writeResponse |
( |
const struct fanotify_response |
response, |
|
|
int |
doBuffer |
|
) |
| |
|
private |
Writes fanotify response.
- Parameters
-
response | response |
doBuffer | if != 0 write to buffer |
- Returns
- success = 0
Definition at line 450 of file FanotifyPolling.cc.
pthread_mutex_t FanotifyPolling::mutex_response |
|
private |
enum Status FanotifyPolling::status |
|
private |
pthread_t FanotifyPolling::thread |
|
private |
The documentation for this class was generated from the following files: