[FFmpeg-devel] [patch]MMS protocol over TCP
Michael Niedermayer
michaelni
Wed Apr 7 21:04:28 CEST 2010
On Thu, Apr 08, 2010 at 01:52:26AM +0800, zhentan feng wrote:
[...]
> mmst.c | 10 ++++++++++
> 1 file changed, 10 insertions(+)
> fbefbb5435158df89472574d36821961d9992244 check_bounds.patch
ok
[...]
> mmst.c | 2 ++
> 1 file changed, 2 insertions(+)
> 4f70bbff3f7978b5aba587e75bb46639215e009d check_realloc_failed.patch
> Index: mmst.c
> ===================================================================
> --- mmst.c (revision 5735)
> +++ mmst.c (working copy)
> @@ -321,6 +321,8 @@
> mms->asf_header = av_realloc(mms->asf_header,
> mms->asf_header_size
> + mms->pkt_buf_len);
> + if (!mms->asf_header)
> + return -1;
thats probably a memleak and should return ENOMEM
> memcpy(mms->asf_header + mms->asf_header_size,
> mms->pkt_read_ptr,
> mms->pkt_buf_len);
> mmst.c | 16 ++++++++++++++--
> 1 file changed, 14 insertions(+), 2 deletions(-)
> 8ef6faa62f18a5616961057ce6e62fcc3a76066c stream_num.patch
ok
[...]
> mmst.c | 20 +++++++-------------
> 1 file changed, 7 insertions(+), 13 deletions(-)
> d3ffd055e2ebf304d29703c8c8d7a27fba97761b remove_function.patch
> Index: mmst.c
> ===================================================================
> --- mmst.c (revision 5737)
> +++ mmst.c (working copy)
> @@ -553,9 +553,9 @@
> return ret;
> }
>
> -static int mms_open_cnx(URLContext *h, const char *url)
> +static int mms_open(URLContext *h, const char *uri, int flags)
> {
> - MMSContext *mms = h->priv_data;
> + MMSContext *mms;
> MMSSCPacketType packet_type;
> int port;
>
> @@ -563,10 +563,14 @@
> int err = AVERROR(EIO);
> int ret;
>
> + h->is_streamed = 1;
> + h->priv_data = av_mallocz(sizeof(MMSContext));
> + mms = (MMSContext *) h->priv_data;
that cast should be unneeded
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Into a blind darkness they enter who follow after the Ignorance,
they as if into a greater darkness enter who devote themselves
to the Knowledge alone. -- Isha Upanishad
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20100407/9a686c51/attachment.pgp>
More information about the ffmpeg-devel
mailing list