Everything

abort


Terminates the program

[Classification]

Standard library

[Syntax]

#include <stdlib.h>

void abort(void);

[Description]

Calling abort(void) terminates the program. An abort function that suits the user system must be created in advance.

[Example]

#include    <assert.h>
int func(void);
int main() {
    int ret;
    ret = func();
    if (ret == 0) {
    abort();       <- abort() is called if ret is not 0
    }
    return 0;
}