[Client] Fix the request loop

8bec37c4 caused the non-flood mode to flood.
This commit is contained in:
Matteo Cypriani 2011-08-26 15:54:46 +02:00
parent 31bea165c5
commit b22a42a524
1 changed files with 5 additions and 4 deletions

View File

@ -101,11 +101,12 @@ int main(int argc, char *argv[])
create_socket() ;
while (owl_run)
send_request() ;
while (owl_run && options.flood_delay >= 0)
{
send_request() ;
if (options.flood_delay >= 0 && owl_run)
owl_msleep(options.flood_delay) ;
owl_msleep(options.flood_delay) ;
if (owl_run) // owl_run can have been set to false during the sleep
send_request() ;
}
close(sockfd) ;