GNU libmicrohttpd 0.9.77
Loading...
Searching...
No Matches
init.c File Reference

initialization routines More...

#include "internal.h"
#include "init.h"
Include dependency graph for init.c:

Go to the source code of this file.

Functions

static void mhd_panic_std (void *cls, const char *file, unsigned int line, const char *reason)
 
void MHD_init (void)
 
void MHD_fini (void)
 
void MHD_check_global_init_ (void)
 

Variables

volatile unsigned int global_init_count = 0
 

Detailed Description

initialization routines

Author
Christian Grothoff

Definition in file init.c.

Function Documentation

◆ MHD_check_global_init_()

void MHD_check_global_init_ ( void  )

Check whether global initialisation was performed and call initialiser if necessary.

Definition at line 136 of file init.c.

References global_init_count, MHD_init(), MHD_mutex_lock_chk_, and MHD_mutex_unlock_chk_.

Referenced by MHD_daemon_create().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ MHD_fini()

void MHD_fini ( void  )

Global teardown work.

Definition at line 115 of file init.c.

References MHD_monotonic_sec_counter_finish().

Here is the call graph for this function:

◆ MHD_init()

void MHD_init ( void  )

Globally initialize library.

Initialize do setup work.

Definition at line 86 of file init.c.

References _, MHD_monotonic_sec_counter_init(), MHD_PANIC, mhd_panic, mhd_panic_std(), and NULL.

Referenced by MHD_check_global_init_().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ mhd_panic_std()

static void mhd_panic_std ( void *  cls,
const char *  file,
unsigned int  line,
const char *  reason 
)
static

Default implementation of the panic function, prints an error message and aborts.

Parameters
clsunused
filename of the file with the problem
lineline number with the problem
reasonerror message with details

Definition at line 61 of file init.c.

References _.

Referenced by MHD_init().

Here is the caller graph for this function:

Variable Documentation

◆ global_init_count

volatile unsigned int global_init_count = 0

Track global initialisation

Definition at line 33 of file init.c.

Referenced by MHD_check_global_init_().