From a3fca2a933b32f405556e5617ce8887eb5b1c243 Mon Sep 17 00:00:00 2001 From: Huw D M Davies Date: Mon, 12 Feb 2001 01:22:01 +0000 Subject: [PATCH] Fix ReleaseStgMedium for MetaFilePict types. --- dlls/ole32/ole2.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dlls/ole32/ole2.c b/dlls/ole32/ole2.c index 2ba71cede12..a812267637e 100644 --- a/dlls/ole32/ole2.c +++ b/dlls/ole32/ole2.c @@ -1462,7 +1462,9 @@ void WINAPI ReleaseStgMedium( if ( (pmedium->pUnkForRelease==0) && (pmedium->u.hMetaFilePict!=0) ) { - DeleteMetaFile(pmedium->u.hMetaFilePict); + LPMETAFILEPICT pMP = GlobalLock(pmedium->u.hMetaFilePict); + DeleteMetaFile(pMP->hMF); + GlobalUnlock(pmedium->u.hMetaFilePict); GlobalFree(pmedium->u.hMetaFilePict); }