diff --git a/dll/directx/wine/d3dx9_36/util.c b/dll/directx/wine/d3dx9_36/util.c index d15444e5cdc..762c1e6034f 100644 --- a/dll/directx/wine/d3dx9_36/util.c +++ b/dll/directx/wine/d3dx9_36/util.c @@ -138,8 +138,10 @@ HRESULT map_view_of_file(const WCHAR *filename, void **buffer, DWORD *length) return S_OK; error: - CloseHandle(hmapping); - CloseHandle(hfile); + if (hmapping) + CloseHandle(hmapping); + if (hfile != INVALID_HANDLE_VALUE) + CloseHandle(hfile); return HRESULT_FROM_WIN32(GetLastError()); } diff --git a/sdk/tools/winesync/d3dx9.cfg b/sdk/tools/winesync/d3dx9.cfg index 9ff89d183a5..8e6beefe8fc 100644 --- a/sdk/tools/winesync/d3dx9.cfg +++ b/sdk/tools/winesync/d3dx9.cfg @@ -34,4 +34,4 @@ files: include/d3dx9tex.h: sdk/include/dxsdk/d3dx9tex.h include/d3dx9xof.h: sdk/include/dxsdk/d3dx9xof.h tags: - wine: 34c0055cfcb84e32d13556b7ec841d01acf5fe96 + wine: e27a95e92097a601baa9b0e9dd6fcc5013c863fa