- Timestamp:
- 2010-03-21T16:06:31Z (15 years ago)
- Branches:
- master
- Children:
- 1cc0df3, 85693e6
- Parents:
- 545d7c0 (diff), a81d679 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
conf.c
r545d7c0 r767a148 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; 65 68 conf->protocols = NULL; 66 69 proxytype = 0; … … 308 311 conf->user = g_strdup( ini->value ); 309 312 } 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 } 310 337 else if( g_strcasecmp( ini->key, "protocols" ) == 0 ) 311 338 {
Note: See TracChangeset
for help on using the changeset viewer.