?

Log in

No account? Create an account
The "x" in extra credit stands for "morbid". Um.. I mean "sucks". Or.. um.. "dragon". - Chaz Meyers [entries|archive|friends|userinfo]
Chaz Meyers

[ website | chazmeyers.com ]
[ profile | view profile ]
[ archive | view archive ]

Links
[Links:| chazmeyers.com Twitter ]

The "x" in extra credit stands for "morbid". Um.. I mean "sucks". Or.. um.. "dragon". [Feb. 18th, 2003|04:27 pm]
Chaz Meyers
// extra credit: catch ^C
void catch_int(int sig_num)
{
    // linux resets the handler when called. eeew.
    // not that it matters since we're exiting anyway...
    signal(SIGINT, catch_int);

    printf("\n\nYea, noise? then I'll be brief. O happy dagger!\n");
    printf("This is thy sheath;\n");
    printf("there rust, and let me die.\n");
    exit();
}
LinkReply

Comments:
[User Picture]From: cpm
2003-02-22 08:23 pm (UTC)
That function is called when you press ^C.

^C kills the program.

It's witty.
(Reply) (Parent) (Thread)