diff --git a/ffserver.c b/ffserver.c index 8687ebaa1f..3efa48b9e0 100644 --- a/ffserver.c +++ b/ffserver.c @@ -2119,11 +2119,10 @@ static int64_t get_packet_send_clock(HTTPContext *c) frame_bytes = c->cur_frame_bytes; if (frame_bytes <= 0) return c->cur_pts; - else { - bytes_left = c->buffer_end - c->buffer_ptr; - bytes_sent = frame_bytes - bytes_left; - return c->cur_pts + (c->cur_frame_duration * bytes_sent) / frame_bytes; - } + + bytes_left = c->buffer_end - c->buffer_ptr; + bytes_sent = frame_bytes - bytes_left; + return c->cur_pts + (c->cur_frame_duration * bytes_sent) / frame_bytes; }