mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-05 23:34:35 +08:00
Merge remote-tracking branch 'qatar/master'
* qatar/master: (25 commits) rtpenc: Add support for G726 audio rtpdec: Interpret the different G726 names as bits_per_coded_sample rtpenc: Change rtp_send_samples to handle sample sizes other than even bytes rtpenc: Cast a rescaling parameter to int64_t h264: cap max has_b_frames at MAX_DELAYED_PIC_COUNT - 1. ARM: fix indentation in ff_dsputil_init_neon() ARM: NEON put/avg_pixels8/16 cosmetics ARM: add remaining NEON avg_pixels8/16 functions ARM: clean up NEON put/avg_pixels macros fate: split acodec-pcm into individual tests swscale: #include "libavutil/mathematics.h" pmpdec: don't use deprecated av_set_pts_info. rv34: align temporary block of "dct" coefs Add PlayStation Portable PMP format demuxer proto: Realign struct initializers proto: Use .priv_data_size to allocate the private context mmsh: Properly clean up if the second ffurl_alloc failed rtmp: Clean up properly if the handshake failed md5proto: Remove the get_file_handle function applehttpproto: Use the close function if the open function fails ... Conflicts: libavcodec/vble.c libavformat/mmsh.c libavformat/pmpdec.c libavformat/udp.c tests/ref/acodec/pcm Merged-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
@ -52,7 +52,6 @@ static int rtmp_close(URLContext *s)
|
||||
RTMP *r = s->priv_data;
|
||||
|
||||
RTMP_Close(r);
|
||||
av_free(r);
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -70,13 +69,9 @@ static int rtmp_close(URLContext *s)
|
||||
*/
|
||||
static int rtmp_open(URLContext *s, const char *uri, int flags)
|
||||
{
|
||||
RTMP *r;
|
||||
RTMP *r = s->priv_data;
|
||||
int rc;
|
||||
|
||||
r = av_mallocz(sizeof(RTMP));
|
||||
if (!r)
|
||||
return AVERROR(ENOMEM);
|
||||
|
||||
switch (av_log_get_level()) {
|
||||
default:
|
||||
case AV_LOG_FATAL: rc = RTMP_LOGCRIT; break;
|
||||
@ -103,11 +98,9 @@ static int rtmp_open(URLContext *s, const char *uri, int flags)
|
||||
goto fail;
|
||||
}
|
||||
|
||||
s->priv_data = r;
|
||||
s->is_streamed = 1;
|
||||
return 0;
|
||||
fail:
|
||||
av_free(r);
|
||||
return rc;
|
||||
}
|
||||
|
||||
@ -167,7 +160,8 @@ URLProtocol ff_rtmp_protocol = {
|
||||
.url_close = rtmp_close,
|
||||
.url_read_pause = rtmp_read_pause,
|
||||
.url_read_seek = rtmp_read_seek,
|
||||
.url_get_file_handle = rtmp_get_file_handle
|
||||
.url_get_file_handle = rtmp_get_file_handle,
|
||||
.priv_data_size = sizeof(RTMP),
|
||||
};
|
||||
|
||||
URLProtocol ff_rtmpt_protocol = {
|
||||
@ -178,7 +172,8 @@ URLProtocol ff_rtmpt_protocol = {
|
||||
.url_close = rtmp_close,
|
||||
.url_read_pause = rtmp_read_pause,
|
||||
.url_read_seek = rtmp_read_seek,
|
||||
.url_get_file_handle = rtmp_get_file_handle
|
||||
.url_get_file_handle = rtmp_get_file_handle,
|
||||
.priv_data_size = sizeof(RTMP),
|
||||
};
|
||||
|
||||
URLProtocol ff_rtmpe_protocol = {
|
||||
@ -189,7 +184,8 @@ URLProtocol ff_rtmpe_protocol = {
|
||||
.url_close = rtmp_close,
|
||||
.url_read_pause = rtmp_read_pause,
|
||||
.url_read_seek = rtmp_read_seek,
|
||||
.url_get_file_handle = rtmp_get_file_handle
|
||||
.url_get_file_handle = rtmp_get_file_handle,
|
||||
.priv_data_size = sizeof(RTMP),
|
||||
};
|
||||
|
||||
URLProtocol ff_rtmpte_protocol = {
|
||||
@ -200,7 +196,8 @@ URLProtocol ff_rtmpte_protocol = {
|
||||
.url_close = rtmp_close,
|
||||
.url_read_pause = rtmp_read_pause,
|
||||
.url_read_seek = rtmp_read_seek,
|
||||
.url_get_file_handle = rtmp_get_file_handle
|
||||
.url_get_file_handle = rtmp_get_file_handle,
|
||||
.priv_data_size = sizeof(RTMP),
|
||||
};
|
||||
|
||||
URLProtocol ff_rtmps_protocol = {
|
||||
@ -211,5 +208,6 @@ URLProtocol ff_rtmps_protocol = {
|
||||
.url_close = rtmp_close,
|
||||
.url_read_pause = rtmp_read_pause,
|
||||
.url_read_seek = rtmp_read_seek,
|
||||
.url_get_file_handle = rtmp_get_file_handle
|
||||
.url_get_file_handle = rtmp_get_file_handle,
|
||||
.priv_data_size = sizeof(RTMP),
|
||||
};
|
||||
|
Reference in New Issue
Block a user