From 12ce0d8638a13ff30d5cf01cbbfe565ccbd19d14 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Sun, 31 Jul 2011 12:11:32 -0700 Subject: [PATCH] Check the primary buffer pointer before dereferencing it --- dsound8.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dsound8.c b/dsound8.c index 565e5222612..5bea08d5a0c 100644 --- a/dsound8.c +++ b/dsound8.c @@ -167,7 +167,7 @@ static void DS8Impl_Destroy(DS8Impl *This) HeapFree(GetProcessHeap(), 0, This->deviceref); } - else if(This->deviceref && This->primary->parent == This) + else if(This->primary && This->primary->parent == This) { /* If the primary is referencing this as its parent, update it to * reference another handle for the device */ -- 2.11.4.GIT