Nilorea Library
C utilities for networking, threading, graphics
Loading...
Searching...
No Matches
ex_signals.c File Reference
#include <stdio.h>
#include <stdlib.h>
#include <stdbool.h>
#include <stdint.h>
#include <string.h>
#include <errno.h>
#include <signal.h>
#include <assert.h>
#include "nilorea/n_signals.h"
#include "nilorea/n_log.h"
#include <libgen.h>
Include dependency graph for ex_signals.c:

Go to the source code of this file.

Functions

void cause_calamity (void)
void cause_segfault (void)
int divide_by_zero (void)
void illegal_instruction (void)
void infinite_loop (void)
int main (int argc, char *argv[])
int stack_overflow (void)

Variables

char * progname = NULL

Function Documentation

◆ cause_calamity()

void cause_calamity ( void )
Examples
ex_signals.c.

Definition at line 70 of file ex_signals.c.

References cause_segfault(), divide_by_zero(), illegal_instruction(), infinite_loop(), and stack_overflow().

Referenced by main().

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

◆ cause_segfault()

void cause_segfault ( void )
Examples
ex_signals.c.

Definition at line 87 of file ex_signals.c.

Referenced by cause_calamity().

Here is the caller graph for this function:

◆ divide_by_zero()

int divide_by_zero ( void )
Examples
ex_signals.c.

Definition at line 81 of file ex_signals.c.

Referenced by cause_calamity().

Here is the caller graph for this function:

◆ illegal_instruction()

void illegal_instruction ( void )
Examples
ex_signals.c.

Definition at line 119 of file ex_signals.c.

Referenced by cause_calamity().

Here is the caller graph for this function:

◆ infinite_loop()

void infinite_loop ( void )
Examples
ex_signals.c.

Definition at line 108 of file ex_signals.c.

Referenced by cause_calamity().

Here is the caller graph for this function:

◆ main()

int main ( int argc,
char * argv[] )

Definition at line 52 of file ex_signals.c.

References cause_calamity(), LOG_DEBUG, LOG_STDERR, n_log, progname, set_log_level(), and set_signal_handler().

Here is the call graph for this function:

◆ stack_overflow()

int stack_overflow ( void )
Examples
ex_signals.c.

Definition at line 99 of file ex_signals.c.

References stack_overflow().

Referenced by cause_calamity(), and stack_overflow().

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

Variable Documentation

◆ progname

char* progname = NULL
Examples
ex_signals.c.

Definition at line 50 of file ex_signals.c.

Referenced by main(), and set_signal_handler().