It's a folder with 362 Icon files.
Thanks for sharing that little detail. I was able to duplicate this easily once I knew what you were talking about (though I suspect they were actually PNG icons, not "icons"). Blame the MM classes...
It's .ICO files of class WPIcon. That is not a subclass of any MM class. Also, I can open the /OS2 folder, hit F5 multiple times with the same effect.
The only thing that helps is to close the folder which will immediately terminate all those refresh threads.
Xworkplace's XFolder replaces the wpPopulate method. If at all, I would suspect this to be the culprit.
As a test, I have reduced to one core only. In that case, the second PMShell instance will not "accumulate" multiple threads. So, this is a serialization issue of the WPS.
I think, I have found the culprit, it is in XFolders "wpRefresh" override method (src\classes\xfldr.c).
That method needs to protect itself against being invoked when a Refresh is already ongoing.
Therefore, it should be extended like this:
SOM_Scope BOOL SOMLINK xf_wpRefresh(XFolder *somSelf,
ULONG ulView,
PVOID pReserved)
{
BOOL rc;
ULONG fFlags;
// XFolderData *somThis = XFolderGetData(somSelf);
XFolderMethodDebug("XFolder","xf_wpRefresh");
fFlags = _wpQueryFldrFlags(somSelf);
if (fFlags & (FOI_REFRESHINPROGRESS | FOI_POPULATEINPROGRESS))
{
return FALSE;
}
_wpModifyFldrFlags(somSelf, FOI_REFRESHINPROGRESS,FOI_REFRESHINPROGRESS);
rc = XFolder_parent_WPFolder_wpRefresh(somSelf, ulView, pReserved);
fdrForEachOpenInstanceView(somSelf,
stb_UpdateCallback,
2); // update
xthrPostWorkerMsg(WOM_REFRESHFOLDERVIEWS,
(MPARAM)somSelf,
(MPARAM)FDRUPDATE_TITLE);
_wpModifyFldrFlags(somSelf, FOI_REFRESHINPROGRESS,0);
return rc;
}
I think it would also be a good idea to remove the "xthrPostWorkerMsg" as there is no need to update the window title of a single refreshed folder and it also executes asynchronously (so, either reset the FOI_REFRESHINPROGRESS flag in the window function posted to from "xthrPostWorkerMsg" or better remove it completely from this spot).
Is there any proper place where I can raise a problem report ?