I think you need to have a virtual destructor (currently you are observing undefined behaviour).
Ancient Dragon commented: good suggestion :) +14
Rage A Lot commented: Thanks +0
mike_2000_17 commented: well spotted! +13
Jsplinter commented: oh my goodness! That's it! Thank you! +3
Salem commented: That's an interesting read +17
Ancient Dragon commented: thanks +36
xxunknown321 commented: Thnx so much +2
jonsca commented: Yes, thanks for pointing that out! +5
Fbody commented: Good idea. Not something you need very often, but very useful when you do. +4
Intrade commented: Finally someone else sees it... +0
Jsplinter commented: Thank you so much! The bullet points made your answer even clearer! +1
Suzie999 commented: Useful information +1
fire_ commented: Thank you. It worked +1
VernonDozier commented: +rep for figuring out the #define. +11
Nick Evan commented: Hmmm.. I'm still not convinced, but I see your point :) +15
mitrmkar 1,056 Posting Virtuoso
creeps commented: Missed that one +1
BobbieJean commented: mitrmkar's respnse to my post was the one that solved it! Thanks a bunch mitrmkar!!! +1