On Wed, Mar 22, 2006 at 11:29:01AM -0300, Gustavo Franco wrote: > > > There's a workaround that is run the application as follows: > > > $ G_SLICE=always-malloc application
> > Thanks for the information. Can you explain (or provide a pointer to) why > > these bugs are application bugs rather than bugs in glib, and does glib need > > to be adding << conflicts with those applications in order to avoid broken > > partial upgrades? > Yes, the new GSlice allocator is triggering those[0] bugs[1]. It happens due > to > different (but similar) reasons, e.g: In nettool and galculator[2] the > code should > call g_object_unref() - that decrease the ref count and frees the memory when > the ref count is zero, instead call g_free() directly. Right, I saw the patch posted to the evolution bug, which made perfect sense -- objects are being allocated via one API and then being freed by another, unrelated API that happened to work before because they were both implemented on top of malloc()/free(). So, unquestionably an application bug. > FYI, GMemChunk (old and deprecated by the upstream) was reimplemented to > use GSlice, so no need to change or rebuild code to be affected due to buggy > code. I don't know exactly why asking GSlice to force allocate and free memory > through "standard malloc" solves the problem, maybe someone else can > clarify this point. It works because g_free() is a wrapper around free(), so if the address passed to g_free() doesn't point to memory allocated using malloc(), glibc will abort as shown. Making sure everything is allocated with malloc() works around this. > Talking about the << conflicts thing. The fact that we don't have a list of > affected applications yet, i'm working on a partial list[3] based on > the bugs already > opened. Hopefully it's less grave than you think. Ok, seems like you have this under control then. :) Cheers, -- Steve Langasek Give me a lever long enough and a Free OS Debian Developer to set it on, and I can move the world. [EMAIL PROTECTED] http://www.debian.org/
signature.asc
Description: Digital signature