[FFmpeg-devel] [PATCH 10/17] avcodec/webvttdec: add some memory checks

Nicolas George george at nsup.org
Sun Sep 21 19:19:43 CEST 2014


Le jour de la Récompense, an CCXXII, Clément Bœsch a écrit :
> So I did that and pushed that part of the patchset, adjusted to use a
> bprint helper.
> 
> Unfortunately, this raises a warning because av_bprint_is_complete()
> doesn't take a const parameter. I was too lazy to actually fix the API,
> but didn't want to cast to hide the warning. If you can send a patch to
> fix the bprint API that would be really appreciated. Thanks :)

Pushed the attached patch to my tree: Michael can pull if no objection.

But you could have not needed it and make the whole set even simpler if you
had added av_bprint_finalize() to the helper itself. Even better, "*got_sub
= sub->num_rects > 0" could have been factored too.

Regards,

-- 
  Nicolas George
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-lavu-bprint-add-const-to-av_bprint_is_complete-argum.patch
Type: text/x-diff
Size: 851 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140921/2ce718be/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140921/2ce718be/attachment.asc>


More information about the ffmpeg-devel mailing list