Main index | Section 2 | Options |
#include <stdlib.h>
The why argument points to a NUL- terminated string specifying a reason of the program's termination (maximum 128 characters long). The args array contains pointers which will be logged numerically (with the kernel's ‘%p’ printf(9) format). The nargs argument specifies the number of pointers in args (maximum 16).
The abort2() system call is intended for use in situations where continuation of a process is impossible or for other definitive reasons is unwanted, and normal diagnostic channels cannot be trusted to deliver the message.
The process is killed with SIGABRT unless the arguments to abort2() are invalid, in which case SIGKILL is used.
#include <stdlib.h>if (weight_kg > max_load) { void *ptrs[3];
ptrs[0] = (void *)(intptr_t)weight_kg; ptrs[1] = (void *)(intptr_t)max_load; ptrs[2] = haystack; abort2("Camel overloaded", 3, ptrs); }
ABORT2 (2) | September 30, 2006 |
Main index | Section 2 | Options |
Please direct any comments about this manual page service to Ben Bullock. Privacy policy.
“ | Our grievance is not just against Unix itself, but against the cult of Unix zealots who defend and nurture it. They take the heat, disease, and pestilence as givens, and, as ancient shamans did, display their wounds, some self-inflicted, as proof of their power and wizardry. We aim, through bluntness and humor, to show them that they pray to a tin god, and that science, not religion, is the path to useful and friendly technology. | ” |
— The Unix Haters' handbook |