/[imapfilter]/imapfilter/imapfilter.c
ViewVC logotype

Diff of /imapfilter/imapfilter.c

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

revision 1.54 by lefcha, Sun Aug 3 17:40:10 2003 UTC revision 1.54.2.1 by lefcha, Fri Aug 8 00:28:47 2003 UTC
# Line 1  Line 1 
1  #include <stdio.h>  #include <stdio.h>
2  #include <stdlib.h>  #include <stdlib.h>
3  #include <string.h>  #include <sys/types.h>
4  #include <unistd.h>  #include <unistd.h>
5    #include <string.h>
6  #include <errno.h>  #include <errno.h>
7  #include <limits.h>  #include <limits.h>
8  #include <setjmp.h>  #include <setjmp.h>
# Line 15  Line 16 
16  #include "buffer.h"  #include "buffer.h"
17    
18  #if defined SSL_TLS || defined ENCRYPTED_PASSWORDS || defined CRAM_MD5  #if defined SSL_TLS || defined ENCRYPTED_PASSWORDS || defined CRAM_MD5
19    #include <openssl/opensslv.h>
20  #include <openssl/crypto.h>  #include <openssl/crypto.h>
21  #endif  #endif
22    
# Line 47  main(int argc, char *argv[]) Line 49  main(int argc, char *argv[])
49  {  {
50          int c, r, f;          int c, r, f;
51          pid_t pid;          pid_t pid;
52          char *confile;          /* Configuration file. */          char *conffile;         /* Configuration file. */
53          account_t *ca;          /* Current account. */          account_t *ca;          /* Current account. */
54          mbox_t *cm;             /* Current mailbox. */          mbox_t *cm;             /* Current mailbox. */
55    
# Line 58  main(int argc, char *argv[]) Line 60  main(int argc, char *argv[])
60          options = (OPTION_DETAILS_NORMAL | OPTION_NAMESPACE);          options = (OPTION_DETAILS_NORMAL | OPTION_NAMESPACE);
61          *charset = 0;          *charset = 0;
62          *logfile = 0;          *logfile = 0;
63          confile = NULL;          conffile = NULL;
64            connpri.sock = connaux.sock = -1;
65    
66          while ((c = getopt(argc, argv, "c:d:hkl:"          while ((c = getopt(argc, argv, "c:d:hkl:"
67  #ifdef ENCRYPTED_PASSWORDS  #ifdef ENCRYPTED_PASSWORDS
# Line 67  main(int argc, char *argv[]) Line 70  main(int argc, char *argv[])
70                      "qvV")) != -1) {                      "qvV")) != -1) {
71                  switch (c) {                  switch (c) {
72                  case 'c':                  case 'c':
73                          confile = optarg;                          conffile = optarg;
74                          break;                          break;
75                  case 'd':                  case 'd':
76                          options |= OPTION_DAEMON_MODE;                          options |= OPTION_DAEMON_MODE;
# Line 122  main(int argc, char *argv[]) Line 125  main(int argc, char *argv[])
125          tty_store();          tty_store();
126          catch_signals();          catch_signals();
127    
128          read_config(confile);          read_config(conffile);
129    
130  #ifdef ENCRYPTED_PASSWORDS  #ifdef ENCRYPTED_PASSWORDS
131          read_passwords();          read_passwords();
# Line 234  main(int argc, char *argv[]) Line 237  main(int argc, char *argv[])
237                  }                  }
238                  if (options & OPTION_DAEMON_MODE &&                  if (options & OPTION_DAEMON_MODE &&
239                      flags & FLAG_SIGUSR1_RECEIVED) {                      flags & FLAG_SIGUSR1_RECEIVED) {
240                          reread_config(confile);                          reread_config(conffile);
241                          continue;                          continue;
242                  }                  }
243                  if (interval)                  if (interval)
# Line 246  main(int argc, char *argv[]) Line 249  main(int argc, char *argv[])
249    
250          lockfile_remove();          lockfile_remove();
251    
252          return 0;          exit(0);
253  }  }
254    
255    

Legend:
Removed from v.1.54  
changed lines
  Added in v.1.54.2.1

webmaster@linux.gr
ViewVC Help
Powered by ViewVC 1.1.26