[MPlayer-cvslog] r24596 - trunk/TOOLS/vfw2menc.c

diego subversion at mplayerhq.hu
Sun Sep 23 22:37:33 CEST 2007


Author: diego
Date: Sun Sep 23 22:37:33 2007
New Revision: 24596

Log:
According to MSDN a thread must call CoUninitialize once for each successful
call it has made to CoInitialize or CoInitializeEx, including any call that
returns S_FALSE. Only the CoUninitialize call corresponding to the CoInitialize
or CoInitializeEx call that initialized the library can close it.
patch by Gianluigi Tiesi, mplayer netfarm it


Modified:
   trunk/TOOLS/vfw2menc.c

Modified: trunk/TOOLS/vfw2menc.c
==============================================================================
--- trunk/TOOLS/vfw2menc.c	(original)
+++ trunk/TOOLS/vfw2menc.c	Sun Sep 23 22:37:33 2007
@@ -298,6 +298,6 @@ cleanup:
     if (fourcc) free(fourcc);
     if (filename) free(filename);
     if (hDriver) CloseDriver(hDriver, 0, 0);
-    if (coinit == S_OK) CoUninitialize();
+    if ((coinit == S_OK) || coinit == S_FALSE) CoUninitialize();
     return ret;
 }



More information about the MPlayer-cvslog mailing list