summaryrefslogtreecommitdiff
path: root/libavformat/avio.c
Commit message (Collapse)AuthorAge
* Merge commit '4b1f5e5090abed6c618c8ba380cd7d28d140f867'Michael Niedermayer2014-08-15
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '4b1f5e5090abed6c618c8ba380cd7d28d140f867': cosmetics: Write NULL pointer inequality checks more compactly Conflicts: libavcodec/dvdsubdec.c libavcodec/h263dec.c libavcodec/libxvid.c libavcodec/rv10.c libavcodec/utils.c libavformat/format.c libavformat/matroskadec.c libavformat/segment.c libavutil/opt.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * cosmetics: Write NULL pointer inequality checks more compactlyGabriel Dume2014-08-15
| | | | | | | | Signed-off-by: Diego Biurrun <diego@biurrun.de>
* | Fix warning if https protocol was requested but isn't available.Carl Eugen Hoyos2014-08-12
| |
* | Merge commit 'ec4f04da1a3462dac429b9d15dee5f027309da15'Michael Niedermayer2014-07-27
|\| | | | | | | | | | | | | | | | | | | * commit 'ec4f04da1a3462dac429b9d15dee5f027309da15': avformat: Mark argument in av_{i|o}format_next/ffurl_protocol_next as const Conflicts: libavformat/format.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avformat: Mark argument in av_{i|o}format_next/ffurl_protocol_next as constDiego Biurrun2014-07-26
| |
* | lavf: Use av_gettime_relative()Olivier Langlois2014-05-17
| | | | | | | | | | | | | | | | | | Whenever av_gettime() is used to measure relative period of time, av_gettime_relative() is prefered as it guarantee monotonic time on supported platforms. Signed-off-by: Olivier Langlois <olivier@trillion01.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avformat/avio: also set generic URL context optionsMichael Niedermayer2014-03-30
| | | | | | | | | | | | This should have no effect currently as there are no such options yet. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf/avio: fix ffurl_alloc error checksLukasz Marek2014-03-06
| | | | | | | | | | | | | | ffurl_alloc doc says it returns >= 0 in case of success. avio treats non-zero as errors. Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
* | lavf/avio: Introduce avio_find_protocol_nameAlexander Strasser2014-02-16
| | | | | | | | | | | | | | Make it possible to find out what protocol will be chosen for a given URL. Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2013-10-30
|\| | | | | | | | | | | | | * qatar/master: lavf: Remove a now useless parameter to ffurl_register_protocol Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: Remove a now useless parameter to ffurl_register_protocolMartin Storsjö2013-10-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This was added in 9b07a2dc02e9 as an ABI hack to allow older code built with lavf 52 to register protocols even if the size of the URLProtocol struct was increased. Later, registering protocols from outside of lavf was removed and this workaround isn't needed any longer since lavf 53. This removes an unchecked malloc and a memory leak for the cases when this workaround actually was used - which it hasn't since lavf 53. Signed-off-by: Martin Storsjö <martin@martin.st>
| * avio: Check for memory allocation failure of private dataDerek Buitenhuis2013-10-29
| | | | | | | | Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
* | Merge commit '53151723e377b9c43f876e20d7f27a17993256c8'Michael Niedermayer2013-10-28
|\| | | | | | | | | | | | | | | | | | | * commit '53151723e377b9c43f876e20d7f27a17993256c8': avio: K&R formatting cosmetics Conflicts: libavformat/avio.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avio: K&R formatting cosmeticsLuca Barbato2013-10-28
| |
| * avio: Use AVERROR_PROTOCOL_NOT_FOUNDLuca Barbato2013-10-21
| | | | | | | | | | | | | | | | When the protocol is missing ffurl_alloc() should return AVERROR_PROTOCOL_NOT_FOUND instead of AVERROR(ENOENT). Bug-Id: 577 CC: libav-stable@libav.org
| * avio: Handle AVERROR_EOF in the same way as the return value 0Michael Niedermayer2013-07-07
| | | | | | | | | | | | | | | | | | This makes sure the ffurl_read_complete function actually returns the number of bytes read, as the documentation of the function says, even if the underlying protocol uses AVERROR_EOF instead of 0. Signed-off-by: Martin Storsjö <martin@martin.st>
* | avio: Check for memory allocation failure of private dataDerek Buitenhuis2013-10-27
| | | | | | | | Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
* | retry_transfer_wrapper(): check for interrupt before operationAndrey Utkin2013-07-12
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Suggest recompilation with openssl or gnutls if the https protocol is not found.Carl Eugen Hoyos2013-07-10
| | | | | | | | Fixes ticket #2765.
* | avformat/avio: Fix EOF handiling of ffurl_read_complete()Michael Niedermayer2013-06-24
| | | | | | | | | | | | Fixes Ticket2537 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf/avio: check for : in filenames for protocols.Nicolas George2013-02-28
| | | | | | | | | | | | | | | | | | If the first "special" character in a filename is a comma, it can introduce protocol options, but only if there is a colon at the end. Otherwise, it is just a filename with a comma. Fix trac ticket #2303.
* | lavf/avio: check that the protocol supports the open mode.Nicolas George2013-02-24
| | | | | | | | Fix trac ticket #2139.
* | Merge commit '4521645b1aee9e9ad8f5cea7b2392cd5f6ffcd26'Michael Niedermayer2012-10-28
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '4521645b1aee9e9ad8f5cea7b2392cd5f6ffcd26': avio: fix pointer type mismatches in avio_enum_protocols() avserver: use socklen_t where appropriate udp: use socklen_t where appropriate network: use HAVE_THREADS instead of local hack af_channelmap: remove stray enum declaration buffersink: remove stray semicolon after function definition Conflicts: libavformat/avio.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avio: fix pointer type mismatches in avio_enum_protocols()Mans Rullgard2012-10-27
| | | | | | | | Signed-off-by: Mans Rullgard <mans@mansr.com>
* | avio: fix sizeof argumentMichael Niedermayer2012-10-19
| | | | | | | | | | Fixes CID732284 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | url_alloc_for_protocol: fix use of uninitialized variableMichael Niedermayer2012-10-19
| | | | | | | | | | Fixes CID703830 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avio: replace ETIMEDOUT by EIOMichael Niedermayer2012-09-08
| | | | | | | | | | | | ETIMEDOUT is not available on all platforms Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Add 'rw_timeout' into URLContextAndrey Utkin2012-08-29
| | | | | | | | | | | | | | | | If set non-zero, limits duration of retry_transfer_wrapper() loop, thus affects ffurl_read*(), ffurl_write() Measured in microseconds. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-08-18
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: mpegvideo_enc: don't use deprecated avcodec_encode_video(). cmdutils: refactor -codecs option. avconv: make -shortest a per-output file option. lavc: add avcodec_descriptor_get_by_name(). lavc: add const to AVCodec* function parameters. swf(dec): replace CODEC_ID with AV_CODEC_ID dvenc: don't use deprecated AVCODEC_MAX_AUDIO_FRAME_SIZE rtmpdh: Do not generate the same private key every time when using libnettle rtp: remove ff_rtp_get_rtcp_file_handle(). rtsp.c: use ffurl_get_multi_file_handle() instead of ff_rtp_get_rtcp_file_handle() avio: add (ff)url_get_multi_file_handle() for getting more than one fd h264: vdpau: fix crash with unsupported colorspace amrwbdec: Decode the fr_quality bit properly Conflicts: Changelog cmdutils.c cmdutils_common_opts.h doc/ffmpeg.texi ffmpeg.c ffmpeg.h ffmpeg_opt.c libavcodec/h264.c libavcodec/options.c libavcodec/utils.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avio: add (ff)url_get_multi_file_handle() for getting more than one fdJordi Ortiz2012-08-17
| | | | | | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-06-22
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: libspeexenc: add supported sample rates and channel layouts. Replace usleep() calls with av_usleep() lavu: add av_usleep() function utvideo: mark interlaced frames as such utvideo: Fix interlaced prediction for RGB utvideo. cosmetics: do not use full path for local headers lavu/file: include unistd.h only when available configure: check for unistd.h log: include unistd.h only when needed lavf: include libavutil/time.h instead of redeclaring av_gettime() Conflicts: configure doc/APIchanges ffmpeg.c ffplay.c libavcodec/utvideo.c libavutil/avutil.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * Replace usleep() calls with av_usleep()Mans Rullgard2012-06-22
| | | | | | | | | | | | | | This reduces the dependency on unistd.h which is not available on all systems. Signed-off-by: Mans Rullgard <mans@mansr.com>
* | url: add ffurl_closep() which also sets the context pointer to NULLMichael Niedermayer2012-06-01
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | lavf: use av_freep() in ffurl_close()Michael Niedermayer2012-06-01
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avio: fix "discards const qualifier from pointer target type" warningMichael Niedermayer2012-05-26
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-05-23
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: os_support: Define SHUT_RD, SHUT_WR and SHUT_RDWR on OS/2 http: Add support for reading http POST reply headers http: Add http_shutdown() for ending writing of posts tcp: Allow signalling end of reading/writing avio: Add a function for signalling end of reading/writing lavfi: fix comment, audio is supported now. lavfi: fix incorrect comment. lavfi: remove avfilter_null_* from public API on next bump. lavfi: remove avfilter_default_* from public API on next bump. lavfi: deprecate default config_props() callback and refactor avfilter_config_links() avfiltergraph: smarter sample format selection. avconv: rename transcode_audio/video to decode_audio/video. asyncts: reset delta to 0 when it's not used. x86: lavc: use %if HAVE_AVX guards around AVX functions in yasm code. dwt: return errors from ff_slice_buffer_init() Conflicts: ffmpeg.c libavfilter/avfilter.c libavfilter/avfilter.h libavfilter/formats.c libavfilter/version.h libavfilter/vf_blackframe.c libavfilter/vf_drawtext.c libavfilter/vf_fade.c libavfilter/vf_format.c libavfilter/vf_showinfo.c libavfilter/video.c libavfilter/video.h Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avio: Add a function for signalling end of reading/writingSamuel Pitoiset2012-05-22
| | | | | | | | Signed-off-by: Martin Storsjö <martin@martin.st>
* | avio: change ffurl_alloc return code.Nicolas George2012-04-28
| | | | | | | | | | If the designated protocol is not found, return AVERROR_PROTOCOL_NOT_FOUND instead of AVERROR(ENOENT).
* | avio: Fix "warning: initialization from incompatible pointer type"Michael Niedermayer2012-02-06
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-29
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: aacenc: Fix LONG_START windowing. aacenc: Fix a bug where deinterleaved samples were stored in the wrong place. avplay: use the correct array size for stride. lavc: extend doxy for avcodec_alloc_context3(). APIchanges: mention avcodec_alloc_context()/2/3 avcodec_align_dimensions2: set only 4 linesizes, not AV_NUM_DATA_POINTERS. aacsbr: ARM NEON optimised sbrdsp functions aacsbr: align some arrays aacsbr: move some simdable loops to function pointers cosmetics: Remove extra newlines at EOF Conflicts: libavcodec/utils.c libavfilter/formats.c libavutil/mem.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * cosmetics: Remove extra newlines at EOFAlex Converse2012-01-27
| |
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-28
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: (71 commits) movenc: Allow writing to a non-seekable output if using empty moov movenc: Support adding isml (smooth streaming live) metadata libavcodec: Don't crash in avcodec_encode_audio if time_base isn't set sunrast: Document the different Sun Raster file format types. sunrast: Add a check for experimental type. libspeexenc: use AVSampleFormat instead of deprecated/removed SampleFormat lavf: remove disabled FF_API_SET_PTS_INFO cruft lavf: remove disabled FF_API_OLD_INTERRUPT_CB cruft lavf: remove disabled FF_API_REORDER_PRIVATE cruft lavf: remove disabled FF_API_SEEK_PUBLIC cruft lavf: remove disabled FF_API_STREAM_COPY cruft lavf: remove disabled FF_API_PRELOAD cruft lavf: remove disabled FF_API_NEW_STREAM cruft lavf: remove disabled FF_API_RTSP_URL_OPTIONS cruft lavf: remove disabled FF_API_MUXRATE cruft lavf: remove disabled FF_API_FILESIZE cruft lavf: remove disabled FF_API_TIMESTAMP cruft lavf: remove disabled FF_API_LOOP_OUTPUT cruft lavf: remove disabled FF_API_LOOP_INPUT cruft lavf: remove disabled FF_API_AVSTREAM_QUALITY cruft ... Conflicts: doc/APIchanges libavcodec/8bps.c libavcodec/avcodec.h libavcodec/libx264.c libavcodec/mjpegbdec.c libavcodec/options.c libavcodec/sunrast.c libavcodec/utils.c libavcodec/version.h libavcodec/x86/h264_deblock.asm libavdevice/libdc1394.c libavdevice/v4l2.c libavformat/avformat.h libavformat/avio.c libavformat/avio.h libavformat/aviobuf.c libavformat/dv.c libavformat/mov.c libavformat/utils.c libavformat/version.h libavformat/wtv.c libavutil/Makefile libavutil/file.c libswscale/x86/input.asm libswscale/x86/swscale_mmx.c libswscale/x86/swscale_template.c tests/ref/lavf/ffm Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * lavf: remove disabled FF_API_OLD_INTERRUPT_CB cruftAnton Khirnov2012-01-27
| |
| * lavf: remove disabled FF_API_OLD_AVIO cruftAnton Khirnov2012-01-27
| |
* | Merge remote-tracking branch 'qatar/master'Michael Niedermayer2012-01-06
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * qatar/master: (21 commits) ipmovie: do not read audio packets before the codec is known truemotion2: check size before GetBitContext initialisation avio: Only do implicit network initialization for network protocols avio: Add an URLProtocol flag for indicating that a protocol uses network adpcm: ADPCM Electronic Arts has always two channels matroskadec: Fix a bug where a pointer was cached to an array that might later move due to a realloc() fate: Add missing reference file from 9b4767e4. mov: Support MOV_CH_LAYOUT_USE_DESCRIPTIONS for labeled descriptions. 4xm: Prevent buffer overreads. mjpegdec: parse RSTn to prevent skipping other data in mjpeg_decode_scan vp3: add fate test for non-zero last coefficient vp3: fix streams with non-zero last coefficient swscale: remove unused U/V arguments from yuv2rgb_write(). timer: K&R formatting cosmetics lavf: cosmetics, reformat av_read_frame(). lavf: refactor av_read_frame() to make it easier to understand. Report an error if pitch_lag is zero in AMR-NB decoder. Revert "4xm: Prevent buffer overreads." 4xm: Prevent buffer overreads. 4xm: pass the correct remaining buffer size to decode_i2_frame(). ... Conflicts: libavcodec/4xm.c libavcodec/mjpegdec.c libavcodec/truemotion2.c libavformat/ipmovie.c libavformat/mov_chan.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
| * avio: Only do implicit network initialization for network protocolsMartin Storsjö2012-01-05
| | | | | | | | | | | | | | | | | | | | The implicit network initialization is set to be removed in the future, but is kept for compatibility. By not doing the implicit initialization for non-network protocols, we avoid the warning about avformat_network_init() not being called for these, where it really doesn't make much sense. Signed-off-by: Martin Storsjö <martin@martin.st>
* | avio: fix handling of , in urlsMichael Niedermayer2011-12-23
| | | | | | | | | | | | Fixes Ticket805 Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avio: Fix handling of filenames that contain :Michael Niedermayer2011-11-24
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avio: Support private options in URLProtocolsMichael Niedermayer2011-11-22
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
* | avio: allow any chars in protocolsMichael Niedermayer2011-11-22
| | | | | | | | Signed-off-by: Michael Niedermayer <michaelni@gmx.at>