act.sa_handler = SIG_IGN;
act.sa_flags = 0;
sigaction(sig, &act, &oldact);
kill(0, sig);
sigaction(sig, &oldact, NULL);
}