Skip to content

Commit b9fefc8

Browse files
author
Uoti Urpala
committed
stream_ffmpeg: fix broken line from 30afc64
Commit 30afc64 ("stream_ffmpeg: switch to libavformat avio API") somehow contained a nonsense line which broke the control() function. Fix. Also add avformat_network_init() to central libav initialization code to avoid warnings.
1 parent 81eb911 commit b9fefc8

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

av_log.c

+1
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,7 @@ void init_libav(void)
112112
av_log_set_callback(mp_msg_av_log_callback);
113113
avcodec_register_all();
114114
av_register_all();
115+
avformat_network_init();
115116
}
116117

117118
#define V(x) (x)>>16, (x)>>8 & 255, (x) & 255

stream/stream_ffmpeg.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ static int seek(stream_t *s, off_t newpos)
5656

5757
static int control(stream_t *s, int cmd, void *arg)
5858
{
59-
AVIOContext *avio = avio;
59+
AVIOContext *avio = s->priv;
6060
int64_t size, ts;
6161
double pts;
6262
switch(cmd) {

0 commit comments

Comments
 (0)