Prevent crash on IDirectMusicLoaderResourceStream_IStream_Read.

This commit is contained in:
Alex Villacís Lasso 2005-06-13 19:05:01 +00:00 committed by Alexandre Julliard
parent 31695b54c9
commit 4a109c7818
1 changed files with 2 additions and 2 deletions

View File

@ -390,9 +390,9 @@ HRESULT WINAPI IDirectMusicLoaderResourceStream_IStream_Read (LPSTREAM iface, vo
memcpy (pv, pByte, cb);
This->llPos += cb; /* move pointer */
/* FIXME: error checking would be nice */
*pcbRead = cb;
if (pcbRead) *pcbRead = cb;
TRACE_(dmfileraw)(": data (size = 0x%08lX): '%s'\n", *pcbRead, debugstr_an(pv, *pcbRead));
TRACE_(dmfileraw)(": data (size = 0x%08lX): '%s'\n", cb, debugstr_an(pv, *pcbRead));
return S_OK;
}