Commit dd16a491 authored by Jacek Caban's avatar Jacek Caban Committed by Alexandre Julliard

mscoree: Use CreateConfigStream in parse_config_file.

parent 8fff6813
......@@ -34,7 +34,6 @@
#include "cordebug.h"
#include "wine/list.h"
#include "mscoree_private.h"
#include "shlwapi.h"
#include "wine/debug.h"
......@@ -664,20 +663,18 @@ HRESULT parse_config_file(LPCWSTR filename, parsed_config_file *result)
init_config(result);
initresult = CoInitializeEx(NULL, COINIT_APARTMENTTHREADED);
hr = SHCreateStreamOnFileW(filename, STGM_SHARE_DENY_WRITE | STGM_READ | STGM_FAILIFTHERE, &stream);
if (SUCCEEDED(hr))
{
V_VT(&var) = VT_UNKNOWN;
V_UNKNOWN(&var) = (IUnknown*)stream;
hr = CreateConfigStream(filename, &stream);
if (FAILED(hr))
return hr;
hr = parse_config(var, result);
initresult = CoInitializeEx(NULL, COINIT_APARTMENTTHREADED);
V_VT(&var) = VT_UNKNOWN;
V_UNKNOWN(&var) = (IUnknown*)stream;
IStream_Release(stream);
}
hr = parse_config(var, result);
IStream_Release(stream);
if (SUCCEEDED(initresult))
CoUninitialize();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment