Welcome to xMule: A P2P Client derived from eMule BerliOS Developer LogoSourceForge.net Logo


Links
- Visit the Forums!
- SF.net Project Page
- xMule Screenshots

Modules
· Home
· Content
· Downloads
· Recommend Us
· Search
· Statistics
· Top
· Topics
· Your Account

Who's Online
There are currently, 2 guest(s) and 0 member(s) that are online.

You are Anonymous user. You can register for free by clicking here

 
The Great Refactor Coding Blog: Great Refactor: Step 5: Remove all memory errors
Posted by HopeSeekr on Monday, July 12 @ 10:17:08 CDT
Contributed by HopeSeekr

We've come a LONG way since eMule 0.26d, when memory would leak at many megs an hour. Now you can run xMule for many hours without noticing much of an increase from the startup memory of 20MB. This will take it to the next level. Memory warnings fixed: 21 out of 39
Memory leaks fixed: 0 out of 5
Initial run: 6664 errors from 43 contexts. Modified at 9:44 (-5 UTC) on 12 July 2004

OK This is eaiser than I thought. Looks like we've done a really good job thus far :-) Discovered memory leaks can be seen in real-time at http://68.90.235.231/~HopeSeekr/memleaks.txt


 
Login
Nickname

Password

Don't have an account yet? You can create one. As a registered user you have some advantages like theme manager, comments configuration and post comments with your name.

Related Links
· More about The Great Refactor
· News by HopeSeekr


Most read story about The Great Refactor:
Our Situation


Article Rating
Average Score: 0
Votes: 0

Please take a second and vote for this article:

Excellent
Very Good
Good
Regular
Bad


Options

 Printer Friendly Printer Friendly


Associated Topics

Coding Blog

"Great Refactor: Step 5: Remove all memory errors" | Login/Create an Account | 3 comments | Search Discussion
The comments are owned by the poster. We aren't responsible for their content.

No Comments Allowed for Anonymous, please register

Re: Great Refactor: Step 5: Remove all memory errors (Score: 1)
by Xaignar on Tuesday, July 13 @ 18:38:55 CDT
(User Info )
Heya HopeSeekr.
I'm afraid that valgrind wont catch all mem bugs as you seem to imply. For instance, it doesn't catch the following:

char somearray[10];
somearray[10] = 0;

though it will catch this:
char* somearray = new char[10];
somearray[10] = 0;

Also, it doesn't always catch stuff like

class* someptr;
if ( <test> ) {
someptr = new <something>[x];
[...]
}
delete[] someptr;

Personally I've already done a quick audit of aMule for the second type of error (which did unearth a couple of bugs), and plan on doing a more throughout audit for other types of errors as well.

Cheers,
Xaignar





PHP-Nuke Copyright © 2005 by Francisco Burzi. This is free software, and you may redistribute it under the GPL.
PHP-Nuke comes with absolutely no warranty, for details, see the license.
Page Generation: 0.04 Seconds