[Mono-bugs] [Bug 362951] GC moves data of Gdk.Pixbuf when creating it with RGB buffer

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Tue Feb 19 13:59:29 EST 2008


User mkestner at novell.com added comment

Mike Kestner <mkestner at novell.com> changed:

           What    |Removed                                         |Added
             Status|NEW                                             |NEEDINFO
      Info Provider|                                                |rothflorian at gmx.de

--- Comment #1 from Mike Kestner <mkestner at novell.com>  2008-02-19 11:59:29 MST ---
I think the problem here is that byte[] is special-cased from a marshaling
standpoint, such that the array is not actually copied to unmanaged memory. 
The reason the method has a PixbufDestroyNotify delegate is to notify the
caller when it can release the data array.

If you hold that byte[] in an instance value, and implement a
PixbufDestroyNotify delegate to release your ref to it, the problem should be

I can probably add an overload for the method which does this automatically and
hides the DestroyNotify param.

Can you try the workaround I describe above and let me know if it resolves the

Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.

More information about the mono-bugs mailing list