mirror of
https://github.com/reactos/wine.git
synced 2024-11-25 04:39:45 +00:00
dmband: Assign to struct instead of using memcpy.
This commit is contained in:
parent
41025d56e3
commit
ea85c5b15b
@ -302,7 +302,7 @@ static HRESULT IDirectMusicBandTrack_IPersistStream_LoadBand (LPPERSISTSTREAM if
|
||||
ERR(": no more memory\n");
|
||||
return E_OUTOFMEMORY;
|
||||
}
|
||||
memcpy(&pNewBand->BandHeader, pHeader, sizeof(DMUS_PRIVATE_BAND_ITEM_HEADER));
|
||||
pNewBand->BandHeader = *pHeader;
|
||||
pNewBand->pBand = (IDirectMusicBandImpl*)((char*)(*ppBand) - offsetof(IDirectMusicBandImpl,BandVtbl));
|
||||
IDirectMusicBand_AddRef(*ppBand);
|
||||
list_add_tail (&This->Bands, &pNewBand->entry);
|
||||
@ -322,6 +322,8 @@ static HRESULT IDirectMusicBandTrack_IPersistStream_ParseBandsList (LPPERSISTSTR
|
||||
IDirectMusicBand* pBand = NULL;
|
||||
DMUS_PRIVATE_BAND_ITEM_HEADER header;
|
||||
|
||||
memset(&header, 0, sizeof header);
|
||||
|
||||
if (pChunk->fccID != DMUS_FOURCC_BANDS_LIST) {
|
||||
ERR_(dmfile)(": %s chunk should be a BANDS list\n", debugstr_fourcc (pChunk->fccID));
|
||||
return E_FAIL;
|
||||
|
Loading…
Reference in New Issue
Block a user