www.delorie.com/djgpp/doc/libc/libc_37.html   search  
libc.a reference

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

abort

Syntax

 
#include <stdlib.h>

void abort(void);

Description

When you call abort, the message "Abort!" is printed on stdout and the program is aborted by calling raise (SIGABRT) (see section SIGABRT). By default, this causes the CPU registers and the call frame stack dump to be printed, and the program then exits with an exit code of -1 (255). If the SIGABRT signal is caught by a handler that returns, the program exits with an exit code of 1.

Return Value

This function does not return.

Portability

ANSI/ISO C C89; C99
POSIX 1003.2-1992; 1003.1-2001

Example

 
if ((q = malloc(100)) == NULL)
  abort();


  webmaster     delorie software   privacy  
  Copyright © 2004     Updated Apr 2004