help-shishi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: more memleaks


From: Simon Josefsson
Subject: Re: more memleaks
Date: Fri, 26 May 2006 14:28:18 +0200
User-agent: Gnus/5.110006 (No Gnus v0.6) Emacs/22.0.50 (gnu/linux)

Elrond <address@hidden> writes:

> On Tue, May 23, 2006 at 04:16:30PM +0200, Simon Josefsson wrote:
> [...]
>> > 1) "realm-kdc" option in shishi.conf.
>> >
>> >    handle->realminfos probably is the one to properly
>> >    deallocate.
>> 
>> Hi!  Done in CVS now, thanks.
>
> good.
>
> So it will be in the daily builds some time soon, right?

Yup, should be in today's build.

>> > 2) shishi_tkts_done should loop over the the tickets and
>> >    call shishi_tkt_done().
>> 
>> This isn't the right solution now, because a ticket may in theory be
>> part of multiple ticket sets.  The function that added the tickets to
>> a ticket set must make sure they are deallocated.  However, the proper
>> solution here is probably to make it possible to add a ticket to a
>> ticket set, and set a flag to tell shishi_tkts_done to deallocate it
>> too.
>
> There are too other possible solutions:
>
> 1) woo-hoo refcounting:
>    If tickets are immutable (I guess so), then this might
>    be an option.
>
> 2) shishi_tkts_add() could duplicate the complete ticket.
>
>
> I'd probably go for (2) unless refcounting seems to offer
> really more flexibility and a good piece of memory saving.

Yes, I prefer 2) for simplicity.  I'll try to work on this now...

/Simon




reply via email to

[Prev in Thread] Current Thread [Next in Thread]