diff mbox series

[FFmpeg-devel,2/2] avformat/dashdec: Increase size of id buffer

Message ID 20210302103848.483203-2-andreas.rheinhardt@gmail.com
State Accepted
Commit 98c5d6b845cb90918a00e589c2918498da5ed6e0
Headers show
Series [FFmpeg-devel,1/2] avformat/dashdec: Ensure strings are zero-terminated
Related show

Checks

Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished
andriy/PPC64_make success Make finished
andriy/PPC64_make_fate success Make fate finished

Commit Message

Andreas Rheinhardt March 2, 2021, 10:38 a.m. UTC
The current size is not enough, see e.g.
http://ftp.itec.aau.at/datasets/DASHDataset2014/TearsOfSteel/1sec/TearsOfSteel_1s_simple_2014_05_09.mpd

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
---
I don't know if there is a fixed size limit or not (probably not),
but 32 is able to accomodate everything I found.

 libavformat/dashdec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

James Almer March 2, 2021, 1:09 p.m. UTC | #1
On 3/2/2021 7:38 AM, Andreas Rheinhardt wrote:
> The current size is not enough, see e.g.
> http://ftp.itec.aau.at/datasets/DASHDataset2014/TearsOfSteel/1sec/TearsOfSteel_1s_simple_2014_05_09.mpd
> 
> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
> ---
> I don't know if there is a fixed size limit or not (probably not),
> but 32 is able to accomodate everything I found.

There is no defined limit, so maybe it should be dynamic? One could 
easily be even more verbose than what the above manifest did, and still 
be compliant.

And FWIW, what is however mentioned is that white spaces aren't allowed, 
so that manifest above is non-compliant.

> 
>   libavformat/dashdec.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/libavformat/dashdec.c b/libavformat/dashdec.c
> index 3a12aefa68..6b43fd6278 100644
> --- a/libavformat/dashdec.c
> +++ b/libavformat/dashdec.c
> @@ -82,7 +82,7 @@ struct representation {
>       AVFormatContext *ctx;
>       int stream_index;
>   
> -    char id[20];
> +    char id[32];
>       char *lang;
>       int bandwidth;
>       AVRational framerate;
>
diff mbox series

Patch

diff --git a/libavformat/dashdec.c b/libavformat/dashdec.c
index 3a12aefa68..6b43fd6278 100644
--- a/libavformat/dashdec.c
+++ b/libavformat/dashdec.c
@@ -82,7 +82,7 @@  struct representation {
     AVFormatContext *ctx;
     int stream_index;
 
-    char id[20];
+    char id[32];
     char *lang;
     int bandwidth;
     AVRational framerate;