Prompt brute force phase

This commit is contained in:
Aram
2016-04-30 07:28:58 +02:00
parent bfa0cf1987
commit daed59ac8f

View File

@ -209,13 +209,14 @@ void have_enough_states(int sig){
} }
if(!space){ if(!space){
printf("\rCollected %zu nonces... ", nonces_collected); printf("\rCollected %zu nonces... ", nonces_collected);
alarm(1);
} else { } else {
total_states = craptev1_sizeof_space(space); total_states = craptev1_sizeof_space(space);
printf("\rCollected %zu nonces... leftover complexity %zu (press any key to start brute-force phase)", nonces_collected, total_states); printf("\rCollected %zu nonces... leftover complexity %zu (press any key to start brute-force phase)", nonces_collected, total_states);
alarm(10);
} }
fflush(stdout); fflush(stdout);
signal(SIGALRM, have_enough_states); signal(SIGALRM, have_enough_states);
alarm(1);
} }
int main (int argc, const char * argv[]) { int main (int argc, const char * argv[]) {