[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [TSVN] Changes in 2634

From: SteveKing <stefankueng_at_gmail.com>
Date: 2005-02-08 13:09:57 CET

On Tue, 08 Feb 2005 11:59:15 +0000, Will Dean <svn@indcomp.co.uk> wrote:
> At 12:51 08/02/2005 +0100, you wrote:
>
> >I don't think I missed the point here. m_bSVNEntryFieldSet does what
> >you say. But the method BuildCacheResponse fills out the response data
> >which is sent back to the shell extension, but doesn't initialize the
> >data if m_bSVNEntryFieldSet is false. So if m_bSVNEntryFieldSet is
> >false, uninitialized data is sent to the shell extension, without it
> >being aware of that!
>
> It's NOT sent back, that's the point. It doesn't send the whole response
> structure, just the first 32 bytes.

Maybe that was your intention. But you didn't clear the m_status.entry
pointer (set to NULL), so in GetAnswerToRequest(), the
sizeof(TSVNCacheResponse) was used for the length to send the data
back.

> >Another thing I noted: the whole cache exe doesn't close properly. It
> >doesn't react to any WM_CLOSE, WM_ENDSESSION, ... messages and
> >therefore is usually 'killed' by the OS in case of a shutdown/logoff.
> >Ok, in case of a shutdown this won't really matter, but in case of a
> >logoff, this can leave memory allocated (mem leak).
>
> Well, it won't respond to WM_ messages, because it doesn't have a message
> loop.

That could (and IMHO should) be changed.

> I can't see where the memory leak would be, though.

The apr pools aren't freed.

> > Also, apr doesn't
> >really like it if it's not closed properly.
>
> I'm not sure it would know. (A dead person doesn't have much of an opinion
> on his own death...)

No, but it will have a mess lying around, including the dead body.

Stefan

-- 
       ___
  oo  // \\      "De Chelonian Mobile"
 (_,\/ \_/ \     TortoiseSVN
   \ \_/_\_/>    The coolest Interface to (Sub)Version Control
   /_/   \_\     http://tortoisesvn.tigris.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tortoisesvn.tigris.org
For additional commands, e-mail: dev-help@tortoisesvn.tigris.org
Received on Tue Feb 8 13:10:58 2005

This is an archived mail posted to the TortoiseSVN Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.