Subj : Re: xpconnect object lifetime using nsIXPCScriptable To : netscape.public.mozilla.jseng From : David Bradley Date : Mon Sep 22 2003 03:23 am Ulrich von Zadow wrote: > we have xpcom components here that inherit from nsIXPCScriptable and > we've run into a situation where we can't seem to get rid of a memory > leak. Basically, we're returning an xpcom component from GetProperty: Do you know for sure what is leaking? Also once you return from GetProperty the holder is destructed and if what ever else has a reference to the object dies, it's endanger of being collected. (might consider return the holder itself) You're function signature is a bit puzzling. Why do you need return both the object and the jsval representation of the object? I suspect there's more going on here than meets the eye. David .