diff --git a/Connector_RTMP/main.cpp b/Connector_RTMP/main.cpp index d5be60d1..c83c45de 100644 --- a/Connector_RTMP/main.cpp +++ b/Connector_RTMP/main.cpp @@ -88,7 +88,8 @@ int main(){ //rightnow = getNowMS(); retval = epoll_wait(poller, events, 1, 100); now = getNowMS(); - if ((retval > 0) || ((now - lastcheck > 1000) && (!ready4data || (snd_cnt - snd_window_at >= snd_window_size)))){ + if ((retval > 0) || ((now - lastcheck > 1) && (!ready4data || (snd_cnt - snd_window_at >= snd_window_size)))){ + lastcheck = now; parseChunk(); fflush(CONN); }