Nog een poging...
This commit is contained in:
parent
66b8de0a86
commit
667859d984
1 changed files with 4 additions and 1 deletions
|
@ -51,6 +51,8 @@ int main(){
|
|||
|
||||
//first timestamp set
|
||||
firsttime = getNowMS();
|
||||
int now = getNowMS();
|
||||
int lastcheck = now;
|
||||
|
||||
#ifdef DEBUG
|
||||
fprintf(stderr, "Doing handshake...\n");
|
||||
|
@ -85,7 +87,8 @@ int main(){
|
|||
//only parse input if available or not yet init'ed
|
||||
//rightnow = getNowMS();
|
||||
retval = epoll_wait(poller, events, 1, 100);
|
||||
if (retval > 0){
|
||||
now = getNowMS();
|
||||
if ((retval > 0) || ((now - lastcheck > 1000) && (!ready4data || (snd_cnt - snd_window_at >= snd_window_size)))){
|
||||
parseChunk();
|
||||
fflush(CONN);
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue