[FFmpeg-devel] OpenJPEG Encoder Merge Request (Fixes #2942)

Michael Bradshaw mjbshaw at gmail.com
Tue Sep 17 02:56:19 CEST 2013


On Mon, Sep 16, 2013 at 2:39 PM, Michael Niedermayer <michaelni at gmx.at>wrote:

> On Mon, Sep 16, 2013 at 11:19:48AM -0600, Michael Bradshaw wrote:
> > On Mon, Sep 16, 2013 at 9:42 AM, Michael Niedermayer <michaelni at gmx.at
> >wrote:
> >
> > > On Mon, Sep 16, 2013 at 08:33:01AM -0600, Michael Bradshaw wrote:
> > > > Hi,
> > > >
> > > > Please merge
> https://github.com/mjbshaw/FFmpeg-OpenJPEG-J2K-Encoder.git
> > > >
> > > > There is a commit that fixes #2942: (
> > > >
> > >
> https://github.com/mjbshaw/FFmpeg-OpenJPEG-J2K-Encoder/commit/a9d78e32f3cb1812dbf8b4f9cda25b18cff27463
> > > > )
> > >
> > > ctx->compress  should be set to NULL after destroying it
> > > also need_destroy_compress should be updated so as to never leave
> > > inconsistent state in the fields
> >
> >
> > Okay, I've added two commits that fix that and fix redundant zeroing:
> > https://github.com/mjbshaw/FFmpeg-OpenJPEG-J2K-Encoder.git
> >
> > The two commits:
> >
> https://github.com/mjbshaw/FFmpeg-OpenJPEG-J2K-Encoder/commit/9ee89bc74b1ae56153fc5ac3983d6c24c2afab17
> >
> https://github.com/mjbshaw/FFmpeg-OpenJPEG-J2K-Encoder/commit/cac7e86d6a251cfeb1e44c37de281c9fcb2003b8
> >
> > I can squash these to one commit if needed. Next time, I'll just submit
> my
> > patches to the mailing list; it's been awhile since I've pushed to my
> repo
> > though so I wanted to go through it this time.
>
> i somehow missed it in my first look but why is compress freed with
> av_free* ?
> it seems to be allocated by some libopenjpeg function and not
> av_malloc()


Hmm... That's been there since the beginning, and in hindsight that (and my
fix for 2942) isn't quite right. Alright, let's retry this from the
beginning. I'll send in a patch in an email in a bit...


More information about the ffmpeg-devel mailing list