To correct this misbehavior in Windows XP, remove the following registry key.
HKEY_LOCAL_MACHINE\SOFTWARE\Classes\CLSID\{87D62D94-71B3-4b9a-9489-5FE6850DC73E}\InProcServer32
This will prevent Explorer from loading shmedia.dll in response to file property queries on these files. This will not effect your ability to play files, get file attributes, or even view thumbnails. Say goodbye to all explorer.exe 100% CPU issues.
And Solution #2 (basically does the same thing, except you are inactivating the file attributes option)...But it WORKS--No more locked .avi files:
Well windows seem to have a REALLY big problem when it comes to reading AVI files. It seems that when you click on an AVI file in explorer, it'll try to read the entire AVI file to determine the width,height, etc. of the AVI file (this is displayed in the Properties window). Now the problem with Windows is that if you have a broken/not fully downloaded AVI file that doesnt contain this info, Windows will scan the entire AVI file trying to figure out all these properties which in the process will probably cause 100% CPU usage and heavy memory usage.
To solve this problem all you have to do is the following:
1. Open up regedit
2. Goto HKEY_CLASSES_ROOT\SystemFileAs
sociations\.avi\shellex\PropertyHandler
3. Delete the "Default" value which should be "{87D62D94-71B3-4b9a-9489-5FE6850DC73E}"
Please note that this will no longer provide you with the windows properties displaying the AVI file information such as width, height, bitrate etc. But its a small price to pay for saving you resources.
Espero que ajude.
Antes de saber isto resolvi o problema de outra maneira... nada que um fopen(path, "w") não resolva
C Rulez