This is the mail archive of the archer@sourceware.org mailing list for the Archer project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Python convenience functions that return GDB values causesegfault


On Wed, Feb 04, 2009 at 11:06:04AM -0700, Tom Tromey wrote:
> >>>>> "Thiago" == Thiago Jung Bauermann <bauerman@br.ibm.com> writes:
> 
> Thiago> I think it's better to return a copy of the value.
> 
> Yeah, I agree.
> 
> This thread, plus Paul's value-related memory leak note, makes me
> wonder whether we ought to try to implement reference counting for
> struct value.  It seems like a big project, though.

Shouldn't be... and Pedro has a helpful patch for you.  It's tucked
away in "[1/2] Inspect extra signal information".  It adds a closure
to values and callbacks to copy and free it.

-- 
Daniel Jacobowitz
CodeSourcery


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]