aboutsummaryrefslogtreecommitdiffstats
path: root/ffserver.c
diff options
context:
space:
mode:
authorReynaldo H. Verdejo Pinochet <reynaldo@osg.samsung.com>2015-06-21 18:43:13 -0300
committerReynaldo H. Verdejo Pinochet <reynaldo@osg.samsung.com>2015-06-21 19:06:00 -0300
commit758c7a5cbc30d7fe40839e11f18f50a73011366b (patch)
treea1722625f6239f67fb5e82fcfc54b85c5eff3200 /ffserver.c
parent683f57354deb81897a1508b946bac6384088e3a8 (diff)
downloadffmpeg-758c7a5cbc30d7fe40839e11f18f50a73011366b.tar.gz
ffserver: drop unneeded else branching
Signed-off-by: Reynaldo H. Verdejo Pinochet <reynaldo@osg.samsung.com>
Diffstat (limited to 'ffserver.c')
-rw-r--r--ffserver.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/ffserver.c b/ffserver.c
index 3efa48b9e0..2de35ba0b9 100644
--- a/ffserver.c
+++ b/ffserver.c
@@ -2220,17 +2220,16 @@ static int http_prepare_data(HTTPContext *c)
} else if (ret == AVERROR(EAGAIN)) {
/* input not ready, come back later */
return 0;
+ }
+ if (c->stream->loop) {
+ avformat_close_input(&c->fmt_in);
+ if (open_input_stream(c, "") < 0)
+ goto no_loop;
+ goto redo;
} else {
- if (c->stream->loop) {
- avformat_close_input(&c->fmt_in);
- if (open_input_stream(c, "") < 0)
- goto no_loop;
- goto redo;
- } else {
no_loop:
/* must send trailer now because EOF or error */
c->state = HTTPSTATE_SEND_DATA_TRAILER;
- }
}
} else {
int source_index = pkt.stream_index;