Changes in conf.c [3ddb7477:90cd6c4]
Legend:
- Unmodified
- Added
- Removed
-
conf.c
r3ddb7477 r90cd6c4 63 63 conf->ping_timeout = 300; 64 64 conf->user = NULL; 65 conf->ft_max_size = SIZE_MAX;66 conf->ft_max_kbps = G_MAXUINT;67 conf->ft_listen = NULL;68 65 conf->protocols = NULL; 69 66 proxytype = 0; … … 311 308 conf->user = g_strdup( ini->value ); 312 309 } 313 else if( g_strcasecmp( ini->key, "ft_max_size" ) == 0 )314 {315 size_t ft_max_size;316 if( sscanf( ini->value, "%zu", &ft_max_size ) != 1 )317 {318 fprintf( stderr, "Invalid %s value: %s\n", ini->key, ini->value );319 return 0;320 }321 conf->ft_max_size = ft_max_size;322 }323 else if( g_strcasecmp( ini->key, "ft_max_kbps" ) == 0 )324 {325 if( sscanf( ini->value, "%d", &i ) != 1 )326 {327 fprintf( stderr, "Invalid %s value: %s\n", ini->key, ini->value );328 return 0;329 }330 conf->ft_max_kbps = i;331 }332 else if( g_strcasecmp( ini->key, "ft_listen" ) == 0 )333 {334 g_free( conf->ft_listen );335 conf->ft_listen = g_strdup( ini->value );336 }337 310 else if( g_strcasecmp( ini->key, "protocols" ) == 0 ) 338 311 { … … 369 342 if( g_strcasecmp( ini->section, "defaults" ) == 0 ) 370 343 { 371 set_t *s = set_find( &irc-> b->set, ini->key );344 set_t *s = set_find( &irc->set, ini->key ); 372 345 373 346 if( s )
Note: See TracChangeset
for help on using the changeset viewer.