RE: Question regarding to memory leak

2011-06-27 Thread Yan, Bob
- From: owner-openssl-us...@openssl.org [mailto:owner-openssl-us...@openssl.org] On Behalf Of Chris Dodd Sent: Friday, June 24, 2011 5:30 PM To: openssl-users@openssl.org Subject: Re: Question regarding to memory leak On Fri, Jun 24, 2011, Yan, Bob wrote: > Hi, > > I have used IBM pur

Re: Question regarding to memory leak

2011-06-24 Thread Chris Dodd
On Fri, Jun 24, 2011, Yan, Bob wrote: Hi, I have used IBM purify to check my test program which invokes openssl library. There are some memory leaks reported by Purify, please see below. Could somebody point to me from which function those leaks were generated, and how to avoid those leak

Re: Question regarding to memory leak

2011-06-24 Thread terr
On Behalf Of t...@terralogic.net > Sent: Friday, June 24, 2011 4:52 PM > To: openssl-users@openssl.org > Subject: Re: Question regarding to memory leak > > I have suggested this before. Write your own memtools. > > > http://www.terralogic.net/developer/developer.html >

Re: Question regarding to memory leak

2011-06-24 Thread Dr. Stephen Henson
On Fri, Jun 24, 2011, Yan, Bob wrote: > Hi, > > I have used IBM purify to check my test program which invokes openssl > library. There are some memory leaks reported by Purify, please see below. > Could somebody point to me from which function those leaks were generated, > and how to avoid tho

RE: Question regarding to memory leak

2011-06-24 Thread Yan, Bob
To: openssl-users@openssl.org Subject: Re: Question regarding to memory leak I have suggested this before. Write your own memtools. http://www.terralogic.net/developer/developer.html I tossed up a couple poor boy examples. Note the calls: struct pfa_ControlBlock chain1 = { ipfa_ControlBlock

Re: Question regarding to memory leak

2011-06-24 Thread terr
I have suggested this before. Write your own memtools. http://www.terralogic.net/developer/developer.html I tossed up a couple poor boy examples. Note the calls: struct pfa_ControlBlock chain1 = { ipfa_ControlBlock } , chain2 = { ipfa_ControlBlock }; pfa_Init( &chain1,

Re: Question regarding to memory leak

2011-06-24 Thread Eric S. Eberhard
As a general comment not all memory leaks reported by these tools are a bad thing. I often write code that has these type of leaks on purpose for performance reasons. For example a function that is called often and malloc's memory ... rather than malloc and free each time (causing context swi