Re: at_fork & at_exit

From: Shankar Unni
Date: Tue Dec 21 2004 - 16:23:26 EST

Arun C Murthy wrote:

Im looking for linux equivalent of the FreeBSD calls:
1. at_fork
2. at_exit

There is an ANSI C equivalent of at_exit: it's called atexit(). Use that instead of OS-specific hacks like at_exit.

No direct analog to at_fork() that I know of, but there's a "sort of" equivalent thing you can use: pthread_atfork(). No reason why you can't use it, even if your program is not multi-threaded..

To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at