[SDL] blocks lost in SDL_CreateRGBASurface
Edward Cullen
screamingwithnosound at googlemail.com
Tue Dec 16 15:57:07 PST 2008
Hello,
As stated in the Valgrind manual, Valgrind nor many of the system
libraries commonly used, are not perfect.
Generally, you have to analyse the results of VG report and determine
whether the error is in your code or in a library.
The error *looks* like it's in "libag_gui" if this is the code you're
debugging, that's great, you've find a bug. If not, you need to do 2
things; report the bug to the library provider and add a filter to the
Valgrind configuration to remove it so you can focus on "your" errors.
Happy 'Griding!
(P.S. I hope this qualifies as a "nice" RTFM ;)
2008/12/12 Josh Matthews <josh at joshmatthews.net>:
> That implies to me that you're not freeing the surface that gets created.
>
> On Fri, Dec 12, 2008 at 2:38 AM, Herbert Elwood Gilliland III
> <herb.gilliland at gmail.com> wrote:
>>
>> Any idea why valgrind would report:
>>
>> ==26170== 442,496 (240 direct, 442,256 indirect) bytes in 4 blocks are
>> definitely lost in loss record 135 of 450
>> ==26170== at 0x4022AB8: malloc (vg_replace_malloc.c:207)
>> ==26170== by 0x41DA6BB: SDL_CreateRGBSurface (in
>> /usr/lib/libSDL-1.2.so.0.11.1)
>> ==26170== by 0x40E2031: AG_SurfaceRGBA (in
>> /usr/local/lib/libag_gui.so.1.0.0)
>> ==26170== by 0x807D548: scale_buffer_to_ag_surface (wswidget.c:44)
>> ==26170== by 0x807E537: move_to_region_xy (wswidget.c:196)
>> ==26170== by 0x807EF12: WholeslideViewerNew (wswidget.c:304)
>> ==26170== by 0x8051444: CreateSlideViewer (gui_wholeslide.c:405)
>> ==26170== by 0x8083596: MouseButtonDown (ws_thumb2.c:118)
>> ==26170== by 0x4193D21: AG_PostEvent (in
>> /usr/local/lib/libag_core.so.1.0.0)
>> ==26170== by 0x40E6574: AG_WidgetMouseButtonDown (in
>> /usr/local/lib/libag_gui.so.1.0.0)
>> ==26170== by 0x40E64A6: AG_WidgetMouseButtonDown (in
>> /usr/local/lib/libag_gui.so.1.0.0)
>> ==26170== by 0x40E64A6: AG_WidgetMouseButtonDown (in
>> /usr/local/lib/libag_gui.so.1.0.0)
>>
>> --
>> H. E. Gilliland III
>>
>> "Astronomy compels the soul to look upwards and leads us from this world
>> to another."
>> — Plato
>>
>> _______________________________________________
>> SDL mailing list
>> SDL at lists.libsdl.org
>> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>>
>
>
> _______________________________________________
> SDL mailing list
> SDL at lists.libsdl.org
> http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org
>
>
More information about the SDL
mailing list