Question about dynamic 2D array using ScopedPointer

OK, have got out the magnifying glass to look at this as closely as I can:
[list][]One difference is that I’m declaring myArray as a private member variable which needs to be accessed elsewhere in the class[/]
[]This means it doesn’t make sense for me to call clear after that initial loop (I assume that I shouldn’t need to use clear in my class destructor, but I have tried this and still get leaks)[/]
[]I don’t include myArray in the constructor initialisation list[/]
[]My class is instantiated inside an AudioProcessor [/]
[]The leak is introduced as soon as I declare myArray as a private member variable (and do nothing else with it at all)[/][/list]

Thanks again for your time & patience.

Then you’re obviously leaking the object that contains it!

Then you’re obviously leaking the object that contains it![/quote]

Face palm time!

I had a bunch of ScopedPointers as other private member variables that weren’t triggering leaks and I therefore didn’t pay attention to calling the destructor for my class from the destructor of the AudioProcessor. ScopedPointers are obviously too idiot proof.

Having called the destructor, everything is working very, very nicely now.

At least the pain and embarrassment of this little exercise mean it’s unlikely I’m going to make this mistake again. Still I suppose there’s a world of fresh mistakes waiting for me to discover out there.

Special thanks guys. You’re all dead-set legends.