From: Janusz Sobczak Date: Mon, 9 Aug 2010 11:23:07 +0000 (+0200) Subject: gpu: pvr: Check OSAllocMem return value. X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cf3ae8d6b4911473cc4798d88a209931ef8edf6d;p=sgx.git gpu: pvr: Check OSAllocMem return value. Signed-off-by: Janusz Sobczak Signed-off-by: Imre Deak --- diff --git a/pvr/mmu.c b/pvr/mmu.c index 728e735..d93e9ff 100644 --- a/pvr/mmu.c +++ b/pvr/mmu.c @@ -815,9 +815,9 @@ struct MMU_HEAP *MMU_Create(struct MMU_CONTEXT *psMMUContext, return NULL; } - OSAllocMem(PVRSRV_OS_PAGEABLE_HEAP, - sizeof(struct MMU_HEAP), (void **)&pMMUHeap, NULL); - if (pMMUHeap == NULL) { + if (OSAllocMem(PVRSRV_OS_PAGEABLE_HEAP, + sizeof(struct MMU_HEAP), (void **)&pMMUHeap, NULL) + != PVRSRV_OK) { PVR_DPF(PVR_DBG_ERROR, "MMU_Create: ERROR call to OSAllocMem failed"); return NULL;