List:MySQL++« Previous MessageNext Message »
From:Warren Young Date:June 21 2006 5:30pm
Subject:Re: Query Object Memory Leak?
View as plain text  
Bill K wrote:
> Maybe a mod. can delete that post?

Ahahaha.  This is a mail list.  I can't delete emails from other 
people's inboxes.  Theoretically I could remove it from the archives, 
but most of the damage has already been done.  Live and learn, dude.  :)

> I am developing code that needs to create query objects often. There 
> seems to be a memory leak - memory not being released by the query 
> object when it goes out of scope.

I think you've misdiagnosed the problem.  I ran your test code on a 
Linux box, and the amount of memory stays static throughout the 
program's run time.  Between this and what I see in the call stack 
window when after it crashes, I think it's more likely that the problem 
is somewhere down in VC++'s runtime library.

If you're motivated enough, an interesting test would be to revert Query 
back to the old style stream mechanism.  (See the v2.0.0 ChangeLog 
entry.)  We couldn't make that reversion permanent, because the old 
stream style is obsolete, but it would tell us whether I'm right about 
where the problem is.  If the symptom changes, it's in the runtime library.
Thread
Query Object Memory Leak?Bill K21 Jun
  • Re: Query Object Memory Leak?Warren Young21 Jun
    • Re: Query Object Memory Leak?Bill K21 Jun
      • Re: Query Object Memory Leak?Warren Young21 Jun
        • Re: Query Object Memory Leak?Bill K21 Jun
          • Re: Query Object Memory Leak?Warren Young21 Jun
            • Re: Query Object Memory Leak?Bill K22 Jun
              • RE: Query Object Memory Leak?Matt Dargavel22 Jun
                • Re: Query Object Memory Leak?Bill K22 Jun
                  • Re: Query Object Memory Leak?Jim Langston22 Jun
                • Re: Query Object Memory Leak?Warren Young23 Jun
              • Re: Query Object Memory Leak?Warren Young23 Jun
                • Re: Query Object Memory Leak?Warren Young23 Jun
                  • RE: Query Object Memory Leak?Matt Dargavel23 Jun