[FFmpeg-trac] #11099(avfilter:new): streamselect filter, map parsing

FFmpeg trac at avcodec.org
Thu Jul 11 21:28:31 EEST 2024


#11099: streamselect filter, map parsing
--------------------------------------+------------------------------------
             Reporter:  ManDay        |                    Owner:  (none)
                 Type:  defect        |                   Status:  new
             Priority:  normal        |                Component:  avfilter
              Version:  unspecified   |               Resolution:
             Keywords:  streamselect  |               Blocked By:
             Blocking:                |  Reproduced by developer:  0
Analyzed by developer:  0             |
--------------------------------------+------------------------------------
Description changed by ManDay:

Old description:

> It seems the streamselect filter (which is important, because it is the
> only method to consistently define substitution macros!) does not parse
> the map beyond the first argument:
>
> {{{
> const int n = strtol(map, &p, 0);
>
> if (map == p)
>     break;
> map = p;
> }}}
>
> will at most read up to the first (unspecified) seperator, whence it
> stops. Instead, I think, should read
>
> {{{
> if (map == p)
>     break;
>
> map = p + (*p != '\0');
> }}}

New description:

 It seems the streamselect filter (which is important, because it is the
 only method to consistently define substitution macros!) does not parse
 the map beyond the first argument:

 {{{
 const int n = strtol(map, &p, 0);

 if (map == p)
     break;
 map = p;
 }}}

 will at most read up to the first (unspecified) seperator, whence it
 stops. Instead, I think, should read

 {{{
 if (map == p)
     break;

 map = p + (*p != '\0');
 }}}

 https://ffmpeg.org/doxygen/trunk/f__streamselect_8c_source.html#l00205

--
-- 
Ticket URL: <https://trac.ffmpeg.org/ticket/11099#comment:1>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list