[FFmpeg-devel] [PATCH 2/9] avcodec/avcodec: Warn about data returned from get_buffer*()

Michael Niedermayer michael at niedermayer.cc
Sun Aug 18 02:32:55 EEST 2024


On Sat, Aug 17, 2024 at 01:32:56AM +0200, epirat07 at gmail.com wrote:
> 
> 
> On 17 Aug 2024, at 1:11, Michael Niedermayer wrote:
> 
> > Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> > ---
> >  doc/APIchanges       | 4 ++++
> >  libavcodec/avcodec.h | 4 ++++
> >  2 files changed, 8 insertions(+)
> >
> > diff --git a/doc/APIchanges b/doc/APIchanges
> > index 173f317ea1b..53d164959c0 100644
> > --- a/doc/APIchanges
> > +++ b/doc/APIchanges
> > @@ -2,6 +2,10 @@ The last version increases of all libraries were on 2024-03-07
> >
> >  API changes, most recent first:
> >
> > +2024-08-xx - xxxxxxxxx - lavc 61.11.100- avcodec.h
> > +  Not really a change but get_buffer*() should not return
> > +  sensitive data
> 
> IMO this is really hard to understand unless you look at exactly this
> commit diff which most people reading the change log will not.
> 
> Maybe instead:
> 
> Clarify the documentation for get_buffer*() functions, making it
> clear that the memory returned by them should not contain sensitive
> information. This is not a change in the API and how it already worked
> before.

ok will apply something very similar to your suggestion

thx

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Its not that you shouldnt use gotos but rather that you should write
readable code and code with gotos often but not always is less readable
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 195 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20240818/a14a9ab6/attachment.sig>


More information about the ffmpeg-devel mailing list