ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/svn/ircd-hybrid/trunk/src/ircd.c
(Generate patch)

Comparing:
ircd-hybrid-8/src/ircd.c (file contents), Revision 1357 by michael, Sat Apr 21 20:47:01 2012 UTC vs.
ircd-hybrid/trunk/src/ircd.c (file contents), Revision 1632 by michael, Sun Nov 4 15:37:10 2012 UTC

# Line 36 | Line 36
36   #include "ircd_signal.h"
37   #include "s_gline.h"
38   #include "motd.h"
39 + #include "conf.h"
40   #include "hostmask.h"
41   #include "numeric.h"
42   #include "packet.h"
# Line 45 | Line 46
46   #include "rng_mt.h"
47   #include "s_auth.h"
48   #include "s_bsd.h"
48 #include "conf.h"
49   #include "log.h"
50   #include "s_misc.h"
51   #include "s_serv.h"      /* try_connections */
# Line 59 | Line 59
59   #include "motd.h"
60   #include "supported.h"
61   #include "watch.h"
62 <
62 > #include "conf_db.h"
63 > #include "conf_class.h"
64  
65   /* /quote set variables */
66   struct SetOptions GlobalSetOptions;
# Line 82 | Line 83 | const char *logFileName = LPATH;
83   const char *pidFileName = PPATH;
84  
85   char **myargv;
85 char ircd_platform[PLATFORMLEN];
86  
87   int dorehash = 0;
88   int doremotd = 0;
# Line 175 | Line 175 | set_time(void)
175    {
176      ilog(LOG_TYPE_IRCD, "Clock Failure (%s), TS can be corrupted",
177           strerror(errno));
178 <    sendto_realops_flags(UMODE_ALL, L_ALL,
178 >    sendto_realops_flags(UMODE_ALL, L_ALL, SEND_NOTICE,
179                           "Clock Failure (%s), TS can be corrupted",
180                           strerror(errno));
181      restart("Clock Failure");
# Line 244 | Line 244 | io_loop(void)
244      if (doremotd)
245      {
246        read_message_file(&ConfigFileEntry.motd);
247 <      sendto_realops_flags(UMODE_ALL, L_ALL,
247 >      sendto_realops_flags(UMODE_ALL, L_ALL, SEND_NOTICE,
248                             "Got signal SIGUSR1, reloading ircd motd file");
249        doremotd = 0;
250      }
# Line 299 | Line 299 | static void
299   initialize_message_files(void)
300   {
301    init_message_file(USER_MOTD, MPATH, &ConfigFileEntry.motd);
302  init_message_file(OPER_MOTD, OPATH, &ConfigFileEntry.opermotd);
302    init_message_file(USER_LINKS, LIPATH, &ConfigFileEntry.linksfile);
303  
304    read_message_file(&ConfigFileEntry.motd);
306  read_message_file(&ConfigFileEntry.opermotd);
305    read_message_file(&ConfigFileEntry.linksfile);
306  
307    init_isupport();
# Line 508 | Line 506 | main(int argc, char *argv[])
506    ConfigFileEntry.configfile = CPATH;  /* Server configuration file */
507    ConfigFileEntry.klinefile  = KPATH;  /* Server kline file         */
508    ConfigFileEntry.xlinefile  = XPATH;  /* Server xline file         */
511  ConfigFileEntry.rxlinefile = RXPATH; /* Server regex xline file   */
512  ConfigFileEntry.rklinefile = RKPATH; /* Server regex kline file   */
509    ConfigFileEntry.dlinefile  = DLPATH; /* dline file                */
510 <  ConfigFileEntry.glinefile  = GPATH;  /* gline log file            */
511 <  ConfigFileEntry.cresvfile  = CRESVPATH; /* channel resv file      */
516 <  ConfigFileEntry.nresvfile  = NRESVPATH; /* nick resv file         */
510 > //  ConfigFileEntry.cresvfile  = CRESVPATH; /* channel resv file      */
511 > //  ConfigFileEntry.nresvfile  = NRESVPATH; /* nick resv file         */
512    myargv = argv;
513    umask(077);                /* better safe than sorry --SRB */
514  
# Line 543 | Line 538 | main(int argc, char *argv[])
538  
539    setup_signals();
540  
546  get_ircd_platform(ircd_platform);
547
541    /* Init the event subsystem */
542    eventInit();
543    /* We need this to initialise the fd array before anything else */
# Line 563 | Line 556 | main(int argc, char *argv[])
556    init_hash();
557    init_ip_hash_table();      /* client host ip hash table */
558    init_host_hash();          /* Host-hashtable. */
566  clear_tree_parse();
559    init_client();
560 <  init_class();
561 <  init_whowas();
560 >  class_init();
561 >  whowas_init();
562    watch_init();
563    init_auth();          /* Initialise the auth code */
564    init_resolver();      /* Needs to be setup before the io loop */
565 +  modules_init();
566    read_conf_files(1);   /* cold start init conf files */
567    init_uid();
568    initialize_server_capabs();   /* Set up default_server_capabs */
# Line 616 | Line 609 | main(int argc, char *argv[])
609    /* add ourselves to global_serv_list */
610    dlinkAdd(&me, make_dlink_node(), &global_serv_list);
611  
612 +  load_kline_database();
613 +  load_dline_database();
614 +  load_gline_database();
615 +  load_xline_database();
616 +  load_resv_database();
617 +
618    if (chdir(MODPATH))
619    {
620      ilog(LOG_TYPE_IRCD, "Could not load core modules. Terminating!");
# Line 653 | Line 652 | main(int argc, char *argv[])
652    /* Setup the timeout check. I'll shift it later :)  -- adrian */
653    eventAddIsh("comm_checktimeouts", comm_checktimeouts, NULL, 1);
654  
655 +  eventAddIsh("save_all_databases", save_all_databases, NULL, DATABASE_UPDATE_TIMEOUT);
656 +
657    if (ConfigServerHide.links_delay > 0)
658      eventAddIsh("write_links_file", write_links_file, NULL, ConfigServerHide.links_delay);
659    else

Diff Legend

Removed lines
+ Added lines
< Changed lines (old)
> Changed lines (new)