Forráskód Böngészése

remove the -cT option

it was another vestige from the compat wrapper.

amends cbac8aa75.
Oswald Buddenhagen 4 éve
szülő
commit
6463a72f12
3 módosított fájl, 5 hozzáadás és 13 törlés
  1. 2 6
      src/config.c
  2. 1 1
      src/config.h
  3. 2 6
      src/main.c

+ 2 - 6
src/config.c

@@ -317,7 +317,7 @@ merge_ops( int cops, int ops[] )
 }
 
 int
-load_config( const char *where, int pseudo )
+load_config( const char *where )
 {
 	conffile_t cfile;
 	store_conf_t *store, **storeapp = &stores;
@@ -331,14 +331,12 @@ load_config( const char *where, int pseudo )
 	char buf[1024];
 
 	if (!where) {
-		assert( !pseudo );
 		nfsnprintf( path, sizeof(path), "%s/." EXE "rc", Home );
 		cfile.file = path;
 	} else
 		cfile.file = where;
 
-	if (!pseudo)
-		info( "Reading configuration file %s\n", cfile.file );
+	info( "Reading configuration file %s\n", cfile.file );
 
 	if (!(cfile.fp = fopen( cfile.file, "r" ))) {
 		sys_error( "Cannot open config file '%s'", cfile.file );
@@ -525,7 +523,5 @@ load_config( const char *where, int pseudo )
 	cfile.err |= merge_ops( gcops, global_conf.ops );
 	if (!global_conf.sync_state)
 		global_conf.sync_state = expand_strdup( "~/." EXE "/" );
-	if (!cfile.err && pseudo)
-		unlink( where );
 	return cfile.err;
 }

+ 1 - 1
src/config.h

@@ -46,6 +46,6 @@ int parse_int( conffile_t *cfile );
 uint parse_size( conffile_t *cfile );
 int getcline( conffile_t *cfile );
 int merge_ops( int cops, int ops[] );
-int load_config( const char *filename, int pseudo );
+int load_config( const char *filename );
 
 #endif

+ 2 - 6
src/main.c

@@ -431,7 +431,7 @@ main( int argc, char **argv )
 	channel_conf_t *chan;
 	string_list_t *channame;
 	char *config = NULL, *opt, *ochar;
-	int oind, cops = 0, op, ops[2] = { 0, 0 }, pseudo = 0, ms_warn = 0;
+	int oind, cops = 0, op, ops[2] = { 0, 0 }, ms_warn = 0;
 
 	tzset();
 	gethostname( Hostname, sizeof(Hostname) );
@@ -595,10 +595,6 @@ main( int argc, char **argv )
 			mvars->list = 1;
 			break;
 		case 'c':
-			if (*ochar == 'T') {
-				ochar++;
-				pseudo = 1;
-			}
 			if (oind >= argc) {
 				error( "-c requires an argument.\n" );
 				return 1;
@@ -747,7 +743,7 @@ main( int argc, char **argv )
 	if (merge_ops( cops, ops ))
 		return 1;
 
-	if (load_config( config, pseudo ))
+	if (load_config( config ))
 		return 1;
 
 	if (!channels) {