ObjectDock plus 1.20.522u leaking threads like crazy

Hello,

I used ObjectDock (freeware) for a long time now and I noticed that it has trouble when I left it running for some time.

After investigating, I found out that it was leaking threads. A lot of them. Leaving the program running for a couple of day would result in 1500+ threads used (only by the O.D. process) and an unresponsivel application.

I reported it and never got anything beyond "we'll look at it". So I bought ObjectDock plus yesterday and left it runnng.

Today, after less than 24 hours, it had a thread count of 900+ and growing. It's leaking thread even faster than the freeware version.

This is a serious problem: each thread uses some stack as well as kernel ressources and the result is that O.D. is slowing down my system over the time quite a lot. If I left it running for a week, it would have deadlocked the machine by using all the available ressources.
1,711 views 2 replies
Reply #1 Top
This is usually attributable to a misbehaving docklet.

Do you have docklets in your dock(s)? If so which ones? Do you have the latest OD+ (1.20.522u)?

The usual docklet troubleshooting method is to remove them 1 by 1 until the problem goes away.


Posted via WinCustomize Browser/Stardock Central
Reply #2 Top
Thank you for your answer. I'm using the latest version (as stated in the totle of my frst post )

I don't think a docklet is responsible. First, I have no docklet installed except shortcuts, second all the extra threads entry points are withing the objectDock.exe module (well, memory mapped zone anyway: at offset 0x12d40 within the application image).

All these threads are waiting for a system synchronisation object (WaitforsingleObject).

But actually, I think found out what is happening. When I check the ObjectDock's handle list, it has my email application process (The bat) open many, many times and it opens it once more every time it spawns a new thread (i.e. every time it checks if there is new mail on the server).

It turns out that all these extra threads are waiting for these handles to close (probably waiting for the application to terminate).

I presume that what is happening is the following: OD is watching running processes in order to update the "application running" indicator. Now, for that, it has a thread that constantly watches the process list and if a new module apears that has the same module image as one of the dock links, it spawns a thread that opens the process handle and waits for it (a call to WaitForSingleObject that will only returns when the process has terminated).

Now for some reason, the watchdog thread has a bug that makes it detect every new thread spawned by my email client as a new process. It will spawn a new thread, thinking a new instance of the application has started. But since this is actually the same process, the new thread will never terminate until I kill my mailer.

And I never stop my mailer

I tried restarting it and all the extra threads in ObjectDock went away.

Conclusion: I removed the link from my dock links list and resolved my problem (not very well: I NEED that application there ). The extra threads stayed until I closed the mailer but didn't come back when I restarted it.

I suggest that the developpers download the demo version of that email client ("The bat!", available from www.ritlabs.com) and check out what's wrong with that watchdog thread.

And if I'm wrong, please tell me so: I'd like to know it