diff mbox series

[FFmpeg-devel,2/6] avformat/rtspdec: use SDP_MAX_SIZE for sdp array

Message ID 1604497047-30429-2-git-send-email-lance.lmwang@gmail.com
State Accepted
Commit 9e2872bc67f74b3014794ce0a0a79bbb4e6fbcfa
Headers show
Series [FFmpeg-devel,1/6] avformat/rtsp: 16384 -> SDP_MAX_SIZE | expand

Checks

Context Check Description
andriy/x86_make fail Make failed

Commit Message

Limin Wang Nov. 4, 2020, 1:37 p.m. UTC
From: Limin Wang <lance.lmwang@gmail.com>

Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
---
 libavformat/rtspdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Martin Storsjö Nov. 4, 2020, 1:44 p.m. UTC | #1
On Wed, 4 Nov 2020, lance.lmwang@gmail.com wrote:

> From: Limin Wang <lance.lmwang@gmail.com>
>
> Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
> ---
> libavformat/rtspdec.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/libavformat/rtspdec.c b/libavformat/rtspdec.c
> index ef084a8..3abf34b 100644
> --- a/libavformat/rtspdec.c
> +++ b/libavformat/rtspdec.c
> @@ -172,7 +172,7 @@ static int rtsp_read_announce(AVFormatContext *s)
> {
>     RTSPState *rt             = s->priv_data;
>     RTSPMessageHeader request = { 0 };
> -    char sdp[4096];
> +    char sdp[SDP_MAX_SIZE];
>     int  ret;

How can we use this define in this file, in patch 2/6, when it's only 
available in rtsp.c and rtspenc.c at this stage (and it's moved to the 
header in patch 3/6)?

// Martin
Limin Wang Nov. 4, 2020, 1:52 p.m. UTC | #2
On Wed, Nov 04, 2020 at 03:44:22PM +0200, Martin Storsjö wrote:
> On Wed, 4 Nov 2020, lance.lmwang@gmail.com wrote:
> 
> > From: Limin Wang <lance.lmwang@gmail.com>
> > 
> > Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
> > ---
> > libavformat/rtspdec.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/libavformat/rtspdec.c b/libavformat/rtspdec.c
> > index ef084a8..3abf34b 100644
> > --- a/libavformat/rtspdec.c
> > +++ b/libavformat/rtspdec.c
> > @@ -172,7 +172,7 @@ static int rtsp_read_announce(AVFormatContext *s)
> > {
> >     RTSPState *rt             = s->priv_data;
> >     RTSPMessageHeader request = { 0 };
> > -    char sdp[4096];
> > +    char sdp[SDP_MAX_SIZE];
> >     int  ret;
> 
> How can we use this define in this file, in patch 2/6, when it's only
> available in rtsp.c and rtspenc.c at this stage (and it's moved to the
> header in patch 3/6)?
Sorry, my fault, the patch order isn't right when I apply to the master.
will reformat them.

> 
> // Martin
>
diff mbox series

Patch

diff --git a/libavformat/rtspdec.c b/libavformat/rtspdec.c
index ef084a8..3abf34b 100644
--- a/libavformat/rtspdec.c
+++ b/libavformat/rtspdec.c
@@ -172,7 +172,7 @@  static int rtsp_read_announce(AVFormatContext *s)
 {
     RTSPState *rt             = s->priv_data;
     RTSPMessageHeader request = { 0 };
-    char sdp[4096];
+    char sdp[SDP_MAX_SIZE];
     int  ret;
 
     ret = rtsp_read_request(s, &request, "ANNOUNCE");