Products
and Services Support
and Docs Training Partner Programs About Red
Hat
  download storecart
red hat logo
redhat.comredhat network

Red Hat Documentation: man pages: man3: Linux Programmer's Manual (3)

Manpage of ON_EXIT

ON_EXIT

Section: Linux Programmer's Manual (3)
Updated: April 2, 2025
Index  

NAME

on_exit - register a function to be called at normal program termination.  

SYNOPSIS

#include <stdlib.h>
int on_exit(void (*function)(int , void *), void *arg);
 

DESCRIPTION

The on_exit() function registers the given function to be called at normal program termination, whether via or via return from the program's main. The function is passed the argument to and the arg argument from on_exit().  

RETURN VALUE

The on_exit() function returns the value 0 if successful; otherwise the value -1 is returned.  

SEE ALSO


 

Index

NAME
SYNOPSIS
DESCRIPTION
RETURN VALUE
SEE ALSO

This document was created by using the manual pages.
Time: 11:58:05 GMT, March 24, 2025

 

 


 
© 2001 Red Hat, Inc. All rights reserved.
About Red Hat  :  Legal statement  :  Privacy statement  :  Y2K statement  :  Contact Red Hat