Re: [AD] [allegro] linux joystick + dmalloc support + leak report

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


> ljoy_2.diff: Adds important version check to the Allegro Linux joystick
> driver.This is the same patch as the old one I sent you Eric, except this
> one should be endian safe. (The ioctl should return JS_VERSION which has
> native endianness AFAIK)

Applied to mainline.

> dmalloc.diff: Adds support for the dmalloc malloc debugger suite. I
> noticed Allegro recently got support for fortify. All I could find on the
> internet was an out of date version 2.2 for DOS which didn't work for me.
> Also I found a Debian package which I did not test. In addition I've toyed
> around with Valgrind and Electric Fence. both good tools, but slow, memory
> hogging or buggy. Valgrind crashes Allegro apps and Electric Fence doesn't
> report memory leaks. Dmalloc seems to be perfect though. It is fast when
> used in the 'runtime' mode and it reports memory leaks and in what
> __FILE__ and __LINE__ the memory were first allocated.

Applied to mainline (the configure script is not in the CVS tree).

> By the way... I found four "memory leaks" with dmalloc which turned out to
> be bogus. Buffers first allocated as follows: src/readsmp.c:52,
> src/readsmp.c:55, src/readbmp.c:51, src/readbmp.c:54. It seems dmalloc
> doesn't like memory freed by an exit handler. I don't care much for
> "Texas" memory management either. :-) the functions for
> register_bitmap_file_type() and register_sample_file_type () should be
> promoted to the API and allegro_exit() should just check if they were
> called (listheads == NULL) to maintain backwards compatibility.

I see no point in promoting them, they are not practically usable from the 
user's point-of-view.

Thanks for the patches!

-- 
Eric Botcazou




Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/