Tracking COM reference counts

Hi Experts,

Does anyone know of a tool that tracks COM reference counts? I have a 3rd party DirectShow object that does not clean up properly as well as an (unrelated) ActiveX control that wont shutdown properly, I could do with something that can be constrained to sets of class instances.

Any ideas?


Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

The return values from AddRef and Release normally provide an indication on the internal reference counts. Not always accurate though. But if Release was to return 0, it's a good sign that things are Ok.
that is no real tracker though.
you can check the refcount at some points but not monitor it...
OWASP: Avoiding Hacker Tricks

Learn to build secure applications from the mindset of the hacker and avoid being exploited.

DavidEllimanAuthor Commented:
Thanks everyone

I know about the AddRef and Release, if it was my code I would reimplement IUnknown but it's third party so I just wanted a simple utility to check.

I've installed boundschecker (which I haven't used for some years) and will try that.
>> that is no real tracker though.
>> you can check the refcount at some points but not monitor it...
I totally agree. Just unwilling to spend money.
there is a trial of boundschecker available...

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
DavidEllimanAuthor Commented:
I know, thanks, I'm using it now :-)
No comment has been added lately, so it's time to clean up this TA. I will
leave a recommendation in the Cleanup topic area that this question is:

Answered: Points to Daij-Djan

Please leave any comments here within the next four days.

Experts: Silence means you don't care. Grading recommendations are made in light
of the posted grading guidlines (


-bcl (bcladd)
EE Cleanup Volunteer

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.