Changes in conf.c [4bfca70:2a6ca4f]
Legend:
- Unmodified
- Added
- Removed
-
conf.c
r4bfca70 r2a6ca4f 46 46 conf = g_new0( conf_t, 1 ); 47 47 48 #ifdef IPV6 49 conf->iface = "::"; 50 #else 48 51 conf->iface = "0.0.0.0"; 52 #endif 49 53 conf->port = 6667; 50 54 conf->nofork = 0; … … 53 57 conf->runmode = RUNMODE_INETD; 54 58 conf->authmode = AUTHMODE_OPEN; 55 conf->password = NULL; 59 conf->auth_pass = NULL; 60 conf->oper_pass = NULL; 56 61 conf->configdir = g_strdup( CONFIG ); 57 62 conf->plugindir = g_strdup( PLUGINDIR ); … … 71 76 } 72 77 73 while( ( opt = getopt( argc, argv, "i:p:nvID c:d:h" ) ) >= 0 )78 while( ( opt = getopt( argc, argv, "i:p:nvIDFc:d:h" ) ) >= 0 ) 74 79 { 75 80 if( opt == 'i' ) … … 94 99 else if( opt == 'D' ) 95 100 conf->runmode=RUNMODE_DAEMON; 101 else if( opt == 'F' ) 102 conf->runmode=RUNMODE_FORKDAEMON; 96 103 else if( opt == 'c' ) 97 104 { … … 118 125 " -I Classic/InetD mode. (Default)\n" 119 126 " -D Daemon mode. (Still EXPERIMENTAL!)\n" 127 " -F Forking daemon. (one process per client)\n" 120 128 " -i Specify the interface (by IP address) to listen on.\n" 121 129 " (Default: 0.0.0.0 (any interface))\n" … … 157 165 if( g_strcasecmp( ini->value, "daemon" ) == 0 ) 158 166 conf->runmode = RUNMODE_DAEMON; 167 else if( g_strcasecmp( ini->value, "forkdaemon" ) == 0 ) 168 conf->runmode = RUNMODE_FORKDAEMON; 159 169 else 160 170 conf->runmode = RUNMODE_INETD; … … 184 194 else if( g_strcasecmp( ini->key, "authpassword" ) == 0 ) 185 195 { 186 conf->password = g_strdup( ini->value ); 196 conf->auth_pass = g_strdup( ini->value ); 197 } 198 else if( g_strcasecmp( ini->key, "operpassword" ) == 0 ) 199 { 200 conf->oper_pass = g_strdup( ini->value ); 187 201 } 188 202 else if( g_strcasecmp( ini->key, "hostname" ) == 0 )
Note: See TracChangeset
for help on using the changeset viewer.