comparison src/aim.c @ 1415:3dfd2a83fb5e

[gaim-migrate @ 1425] woo hoo committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Fri, 19 Jan 2001 09:11:16 +0000
parents 17e544f8c7fb
children b4de935f820f
comparison
equal deleted inserted replaced
1414:ebfde8fc7e73 1415:3dfd2a83fb5e
385 extern void show_debug(GtkObject *); 385 extern void show_debug(GtkObject *);
386 386
387 #if HAVE_SIGNAL_H 387 #if HAVE_SIGNAL_H
388 void sighandler(int sig) 388 void sighandler(int sig)
389 { 389 {
390 fprintf(stderr, "God damn, I tripped.\n"); 390 debug_printf("caught signal %d\n", sig);
391 exit(11); /* signal 11 */ 391 gtkspell_stop();
392 switch (sig) {
393 case SIGSEGV:
394 g_print("Gaim has segfaulted and attempted to dump a core file.\n"
395 "Please notify the gaim maintainers by reporting a bug at\n"
396 "http://sourceforge.net/projects/gaim/\n\n"
397 "Please make sure to specify what you were doing at the time,\n"
398 "and post the backtrace from the core file (if you do not know\n"
399 "how to get the backtrace, please IM either EWarmenhoven or\n"
400 "RobFlynn and they can instruct you).\n");
401 abort();
402 break;
403 case SIGPIPE:
404 /* should we do something here? */
405 default:
406 gtk_main_quit();
407 exit(0);
408 }
392 } 409 }
393 #endif 410 #endif
394 411
395 412
396 int main(int argc, char *argv[]) 413 int main(int argc, char *argv[])
431 textdomain(PACKAGE); 448 textdomain(PACKAGE);
432 #endif 449 #endif
433 450
434 #if HAVE_SIGNAL_H 451 #if HAVE_SIGNAL_H
435 /* Let's not violate any PLA's!!!! */ 452 /* Let's not violate any PLA's!!!! */
436 /* signal(SIGSEGV, sighandler); */ 453 signal(SIGSEGV, sighandler);
454 signal(SIGHUP, sighandler);
455 signal(SIGINT, sighandler);
456 signal(SIGPIPE, sighandler);
437 #endif 457 #endif
438 458
439 459
440 #ifdef USE_APPLET 460 #ifdef USE_APPLET
441 init_applet_mgr(argc, argv); 461 init_applet_mgr(argc, argv);