/[anubis]/anubis/src/main.c
ViewVC logotype

Diff of /anubis/src/main.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.3 by gray, Wed Feb 5 21:50:41 2003 UTC revision 1.4 by polak, Fri Feb 28 20:39:44 2003 UTC
# Line 1  Line 1 
1  /*  /*
2     GNU Anubis v3.6.3 -- an outgoing mail processor and the SMTP tunnel.     GNU Anubis v3.9.0 -- an outgoing mail processor and the SMTP tunnel.
3     Copyright (C) 2001, 2002, 2003 The Anubis Team.     Copyright (C) 2001, 2002, 2003 The Anubis Team.
4    
5     GNU Anubis is free software; you can redistribute it and/or modify     GNU Anubis is free software; you can redistribute it and/or modify
# Line 22  Line 22 
22    
23  #include "headers.h"  #include "headers.h"
24  #include "extern.h"  #include "extern.h"
25  #include "main.h"  
26    const char version[] = "GNU Anubis v"VERSION;
27    const char copyright[] = "Copyright (C) 2001, 2002, 2003 The Anubis Team.";
28    
29    struct options_struct options;
30    struct session_struct session;
31    struct rm_struct rm;
32    #if defined(HAVE_TLS) || defined(HAVE_SSL)
33    struct secure_struct secure;
34    #endif /* HAVE_TLS or HAVE_SSL */
35    
36    unsigned long topt;
37    void *remote_client;
38    void *remote_server;
39    
40  #ifdef WITH_GUILE  #ifdef WITH_GUILE
41  void  void
# Line 33  anubis_core() Line 46  anubis_core()
46  }  }
47  #else  #else
48  # define anubis_core() anubis(NULL)  # define anubis_core() anubis(NULL)
49  #endif  #endif /* WITH_GUILE */
50    
51  int  int
52  main(int argc, char *argv[])  main(int argc, char *argv[])
# Line 54  main(int argc, char *argv[]) Line 67  main(int argc, char *argv[])
67    
68  #ifdef ENABLE_NLS  #ifdef ENABLE_NLS
69           /* Set locale via LC_ALL.  */           /* Set locale via LC_ALL.  */
70  # ifdef HAVE_SETLOCALE  #ifdef HAVE_SETLOCALE
71            setlocale(LC_ALL, "");            setlocale(LC_ALL, "");
72  # endif /* HAVE_SETLOCALE */  #endif /* HAVE_SETLOCALE */
73           bindtextdomain(PACKAGE, LOCALEDIR);           bindtextdomain(PACKAGE, LOCALEDIR);
74           textdomain(PACKAGE);           textdomain(PACKAGE);
75  #endif /* ENABLE_NLS */  #endif /* ENABLE_NLS */
# Line 77  main(int argc, char *argv[]) Line 90  main(int argc, char *argv[])
90          anubis_getlogin(session.supervisor, sizeof(session.supervisor));          anubis_getlogin(session.supervisor, sizeof(session.supervisor));
91    
92          /*          /*
93             Initialize the rc parsing subsystem             Initialize the rc parsing subsystem.
94               Read the system configuration file (SUPERVISOR).
95          */          */
96    
97          rc_system_init();          rc_system_init();
           
         /*  
           Read the system configuration file (SUPERVISOR).  
         */  
98    
99          if (topt & T_CHECK_CONFIG) {          if (topt & T_CHECK_CONFIG) {
100                  open_rcfile(CF_SUPERVISOR);                  open_rcfile(CF_SUPERVISOR);
101                  exit(0);                  exit(0);
102          }          }
           
103          if (!(topt & T_NORC)) {          if (!(topt & T_NORC)) {
104                  open_rcfile(CF_SUPERVISOR);                  open_rcfile(CF_SUPERVISOR);
105                  process_rcfile(CF_INIT);                  process_rcfile(CF_INIT);
106          }          }
107    
108          /*          /* DEBUG */
            DEBUG  
         */  
109    
110  #if defined(HAVE_GETRLIMIT) && defined(HAVE_SETRLIMIT)  #if defined(HAVE_GETRLIMIT) && defined(HAVE_SETRLIMIT)
111          if (options.termlevel != DEBUG) {          if (options.termlevel != DEBUG) {
# Line 113  main(int argc, char *argv[]) Line 121  main(int argc, char *argv[])
121                  (int)getgid(), (int)geteuid(), (int)getegid());                  (int)getgid(), (int)geteuid(), (int)getegid());
122    
123          /*          /*
124             Initialize the GnuTLS or OpenSSL library and the PRNG.             Initialize GnuTLS or OpenSSL library and the PRNG.
125          */          */
126    
127  #ifdef HAVE_TLS  #ifdef HAVE_TLS
# Line 127  main(int argc, char *argv[]) Line 135  main(int argc, char *argv[])
135          /*          /*
136             Enter the main core...             Enter the main core...
137          */          */
138    
139          anubis_core();          anubis_core();
140          return 0;          return 0;
141  }  }

Legend:
Removed from v.1.3  
changed lines
  Added in v.1.4

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26