comparison mcabber/src/main.c @ 1437:071c8170b7de

Add option 'statefile' to keep track of unread messages across restarts (Suggested by micressor)
author Mikael Berthe <mikael@lilotux.net>
date Mon, 25 Feb 2008 20:27:56 +0100
parents a64778f5f26b
children 00503a68f431
comparison
equal deleted inserted replaced
1436:6fb141142388 1437:071c8170b7de
497 #ifdef ENABLE_FIFO 497 #ifdef ENABLE_FIFO
498 /* Initialize FIFO named pipe */ 498 /* Initialize FIFO named pipe */
499 fifo_init(settings_opt_get("fifo_name")); 499 fifo_init(settings_opt_get("fifo_name"));
500 #endif 500 #endif
501 501
502 /* Load previous roster state */
503 hlog_load_state();
504
502 if (ret < 0) { 505 if (ret < 0) {
503 scr_LogPrint(LPRINT_NORMAL, "No configuration file has been found."); 506 scr_LogPrint(LPRINT_NORMAL, "No configuration file has been found.");
504 scr_ShowBuddyWindow(); 507 scr_ShowBuddyWindow();
505 } else { 508 } else {
506 /* Connection */ 509 /* Connection */
537 #ifdef HAVE_GPGME 540 #ifdef HAVE_GPGME
538 gpg_terminate(); 541 gpg_terminate();
539 #endif 542 #endif
540 #ifdef HAVE_ASPELL_H 543 #ifdef HAVE_ASPELL_H
541 /* Deinitialize aspell */ 544 /* Deinitialize aspell */
542 if (settings_opt_get_int("aspell_enable")) { 545 if (settings_opt_get_int("aspell_enable"))
543 spellcheck_deinit(); 546 spellcheck_deinit();
544 } 547 #endif
545 #endif 548 /* Save pending message state */
549 hlog_save_state();
546 550
547 printf("\n\nThanks for using mcabber!\n"); 551 printf("\n\nThanks for using mcabber!\n");
548 552
549 return 0; 553 return 0;
550 } 554 }