Is a prototype for shutdown code for a UNIX style library.
#include <unistd.h> int _fini ( void );
If successful in cleaning up your resources, the _fini function should return 0. Any other value indicates an error.
The _fini function prepares your library for unloading and should perform any required resource clean up so that your library can unload cleanly. You should write an _fini function only if you have also written an _init function to initialize your library.
Don’t write a _fini function without first implementing an _init function.
int _fini( void ) { if (initted) pthread_key_delete(gKey); return 0; }