diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2004-07-25 11:59:34 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2004-07-25 11:59:34 +0000 |
commit | 53e2f9caf80ed385a3d4cfb9200d8827b65580ef (patch) | |
tree | 821ceae2581e009ac37615348e25a5be6f6c4578 /libavformat/utils.c | |
parent | ebb177ddef238db201a2bbbf0db21a6d7fbeba32 (diff) | |
download | ffmpeg-53e2f9caf80ed385a3d4cfb9200d8827b65580ef.tar.gz |
ffserver fixes by (Koos Vriezen <koos.vriezen at xs4all dot nl>)
Originally committed as revision 3340 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavformat/utils.c')
-rw-r--r-- | libavformat/utils.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c index 04e11e2070..be3df4a6e7 100644 --- a/libavformat/utils.c +++ b/libavformat/utils.c @@ -428,7 +428,13 @@ int av_open_input_file(AVFormatContext **ic_ptr, const char *filename, if (!fmt) { /* read probe data */ pd->buf_size = get_buffer(pb, buf, PROBE_BUF_SIZE); - url_fseek(pb, 0, SEEK_SET); + if (url_fseek(pb, 0, SEEK_SET) == (offset_t)-EPIPE) { + url_fclose(pb); + if (url_fopen(pb, filename, URL_RDONLY) < 0) { + err = AVERROR_IO; + goto fail; + } + } } } |