Commit 2fbe8d23 authored by Nikolay Sivov's avatar Nikolay Sivov Committed by Alexandre Julliard

msi: Fix potential NULL pointer dereference in ILockBytes_Release (Coverity).

parent 9598a509
...@@ -134,7 +134,7 @@ static UINT STORAGES_get_row( struct tagMSIVIEW *view, UINT row, MSIRECORD **rec ...@@ -134,7 +134,7 @@ static UINT STORAGES_get_row( struct tagMSIVIEW *view, UINT row, MSIRECORD **rec
static HRESULT stream_to_storage(IStream *stm, IStorage **stg) static HRESULT stream_to_storage(IStream *stm, IStorage **stg)
{ {
ILockBytes *lockbytes; ILockBytes *lockbytes = NULL;
STATSTG stat; STATSTG stat;
LPVOID data; LPVOID data;
HRESULT hr; HRESULT hr;
...@@ -177,7 +177,7 @@ static HRESULT stream_to_storage(IStream *stm, IStorage **stg) ...@@ -177,7 +177,7 @@ static HRESULT stream_to_storage(IStream *stm, IStorage **stg)
done: done:
msi_free(data); msi_free(data);
ILockBytes_Release(lockbytes); if (lockbytes) ILockBytes_Release(lockbytes);
return hr; 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