@ -130,11 +130,13 @@ static int insert_record(struct DB_SYNC_INSTANCE* si, struct UTUN_INSTANCE* inst
}
}
int main ( void ) {
int main ( void ) {
g_seed = ( unsigned int ) time ( NULL ) ;
g_seed = 1784385257 ; /* FIXME: debug — restore time(NULL) after fix */
srand ( g_seed ) ;
srand ( g_seed ) ;
debug_config_init ( ) ;
debug_config_init ( ) ;
debug_set_category_level ( DEBUG_CATEGORY_DEBUG , DEBUG_LEVEL_WARN ) ;
debug_set_category_level ( DEBUG_CATEGORY_DEBUG , DEBUG_LEVEL_TRACE ) ;
debug_set_category_level ( DEBUG_CATEGORY_DB_SYNC , DEBUG_LEVEL_TRACE ) ;
debug_set_category_level ( DEBUG_CATEGORY_ETCP , DEBUG_LEVEL_TRACE ) ;
if ( create_temp_configs ( ) ! = 0 ) { fprintf ( stderr , " FAIL: config creation \n " ) ; return 1 ; }
if ( create_temp_configs ( ) ! = 0 ) { fprintf ( stderr , " FAIL: config creation \n " ) ; return 1 ; }
debug_enable_file_output ( log_path , 1 ) ;
debug_enable_file_output ( log_path , 1 ) ;
@ -241,6 +243,7 @@ cleanup:
int result = ( test_phase = = 0 ) ? 0 : 1 ;
int result = ( test_phase = = 0 ) ? 0 : 1 ;
fprintf ( stderr , " === %s seed=%u (log: %s) === \n " , result ? " FAIL " : " PASS " , g_seed , log_path ) ;
fprintf ( stderr , " === %s seed=%u (log: %s) === \n " , result ? " FAIL " : " PASS " , g_seed , log_path ) ;
cleanup_temp_configs ( ) ;
/* FIXME: debug — restore cleanup_temp_configs() after fix */
/* cleanup_temp_configs(); */
return result ;
return result ;
}
}