Commit 973355f6 authored by Dmitry Timoshkov's avatar Dmitry Timoshkov Committed by Alexandre Julliard

Return STG_E_FILEALREADYEXISTS in ole32.StgOpenStorage if the file is

not a storage object.
parent 270bc587
......@@ -5485,6 +5485,11 @@ HRESULT WINAPI StgOpenStorage(
if (FAILED(hr))
{
HeapFree(GetProcessHeap(), 0, newStorage);
/*
* According to the docs if the file is not a storage, return STG_E_FILEALREADYEXISTS
*/
if(hr == STG_E_INVALIDHEADER)
return STG_E_FILEALREADYEXISTS;
return hr;
}
......
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