suricata
util-daemon.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void Daemonize (void)
 Daemonize the process. More...
 
int CheckValidDaemonModes (int, int)
 Check for a valid combination daemon/mode. More...
 

Detailed Description

Author
Gerardo Iglesias Galvan igles.nosp@m.iasg.nosp@m.@gmai.nosp@m.l.co.nosp@m.m

Definition in file util-daemon.h.

Function Documentation

◆ CheckValidDaemonModes()

int CheckValidDaemonModes ( int  daemon,
int  mode 
)

Check for a valid combination daemon/mode.

Parameters
daemondaemon on or off
modeselected mode
Return values
1valid combination
0invalid combination

Definition at line 177 of file util-daemon.c.

References RUNMODE_PCAP_FILE, RUNMODE_UNITTEST, SCLogDebug, and SCLogError.

◆ Daemonize()

void Daemonize ( void  )

Daemonize the process.

Todo:
We should check if we allow more than 1 instance to run simultaneously. Maybe change the behaviour through conf file

Definition at line 101 of file util-daemon.c.