From the forum thread: https://sourceforge.net/forum/forum.php?thread_id=1675042&forum_id=261542
By: Chris (captainc_) - 2007-02-16 17:12
I get a Heap Leak every time that I use the --help switch or usage information is posted. If valid arguments are used, then there is no leak and everything runs fine. Also, I cannot create my own class to override version, failure, and usage messages as it always leads to a heap leak. I'm not sure what to do about this.
I found that this is happening when I call the isSet() method to test for which arguments were set due to using the xorAdd method. The weird part is that it detects the leak at this method call only when an invalid argument or --help or the like is specified. This occurs whether or not I specify my own output object.
If i specify my own output object and give it valid parameters, then a heap leak is detected on exit of the program.