dmloader: pObject NULL checks are not necessary (Coverity).

This commit is contained in:
Marcus Meissner 2009-12-11 00:10:02 +01:00 committed by Alexandre Julliard
parent 9815898840
commit 6891b96364
1 changed files with 6 additions and 10 deletions

View File

@ -333,18 +333,14 @@ static HRESULT WINAPI IDirectMusicLoaderImpl_IDirectMusicLoader_GetObject (LPDIR
if (!pObjectEntry) {
pObjectEntry = HeapAlloc (GetProcessHeap (), HEAP_ZERO_MEMORY, sizeof(WINE_LOADER_ENTRY));
DM_STRUCT_INIT(&pObjectEntry->Desc);
if (pObject) {
DMUSIC_CopyDescriptor (&pObjectEntry->Desc, &GotDesc);
pObjectEntry->pObject = pObject;
pObjectEntry->bInvalidDefaultDLS = FALSE;
}
DMUSIC_CopyDescriptor (&pObjectEntry->Desc, &GotDesc);
pObjectEntry->pObject = pObject;
pObjectEntry->bInvalidDefaultDLS = FALSE;
list_add_head (This->pObjects, &pObjectEntry->entry);
} else {
if (pObject) {
DMUSIC_CopyDescriptor (&pObjectEntry->Desc, &GotDesc);
pObjectEntry->pObject = pObject;
pObjectEntry->bInvalidDefaultDLS = FALSE;
}
DMUSIC_CopyDescriptor (&pObjectEntry->Desc, &GotDesc);
pObjectEntry->pObject = pObject;
pObjectEntry->bInvalidDefaultDLS = FALSE;
}
TRACE(": filled in cache entry\n");
} else TRACE(": caching disabled\n");