[Ffmpeg-devel] [PATCH] ported SGI decoder to the new API

Xiaohui Sun sunxiaohui
Tue Mar 27 04:10:27 CEST 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Michael Niedermayer wrote:
> Hi
> 
> On Mon, Mar 26, 2007 at 10:28:30AM +0800, Xiaohui Sun wrote:
> [...]
>>> [...]
>>>> +
>>>> + for (z = 0; z < zsize; z++) {
>>>> + for (y = 0; y < ysize; y++) {
>>>> + dest_row = ptr + (ysize - 1 - y) * (xsize * zsize);
>>> whatever this is supposed to do the multiplication can overflow
>>> which considering this is a destination pointer to write is not good
>> then where should the decoded buffer be written to.
> 
> whereever you like, just not in unallocated memory

I have allocated buffer in line 234 : avctx->get_buffer(avctx, p) I am
not is this the right place to do the allocation?

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFGCH0T+BwsLu3sVWwRAp48AJ9w9TO0p2tMuVLtKdWelyHwnvzAKQCgwHnK
fq1I0YPR5tJMvV9MY0UQ/FQ=
=vpeC
-----END PGP SIGNATURE-----





More information about the ffmpeg-devel mailing list