Example #1
0
void gtcm_exit()
{
	op_lkinit();
	op_unlock();
	gv_rundown();
#ifdef GTCM_RC
	rc_delete_cpt();
	rc_rundown();
#endif
	exit(gtcm_exi_condition);
}
Example #2
0
/* signal handler called when the process is about to core dump */
void gtcm_fail(int sig)
{
	void rc_rundown();
        struct sigaction def;

	FPRINTF(stderr,"GT.CM terminating on signal %d, cleaning up...\n", sig);
	/* quickie cleanup */
	rc_rundown();

	sigemptyset(&def.sa_mask);
	def.sa_flags = 0;
	def.sa_handler = SIG_DFL;
	(void) sigaction(SIGQUIT, &def, 0);
	kill(getpid(),SIGQUIT);
        EXIT(sig);
}