From e2c2a5cefe6e87fcd24f4aea19bbc176e657d4a6 Mon Sep 17 00:00:00 2001 From: Alexander von Gluck IV Date: Wed, 26 Feb 2014 15:23:53 -0600 Subject: [PATCH] radeon_hd: Fix app_server bt regression introduced at hrev46862 * We adjusted the array of pointers to be larger, but didn't adjust the malloc to be larger. * Should solve #10563 and maybe #10536 --- src/add-ons/accelerants/radeon_hd/accelerant.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/add-ons/accelerants/radeon_hd/accelerant.cpp b/src/add-ons/accelerants/radeon_hd/accelerant.cpp index 51383281b1..e649f57a2a 100644 --- a/src/add-ons/accelerants/radeon_hd/accelerant.cpp +++ b/src/add-ons/accelerants/radeon_hd/accelerant.cpp @@ -134,7 +134,7 @@ init_common(int device, bool isClone) } // malloc for card gpio pin information - for (uint32 id = 0; id < ATOM_MAX_SUPPORTED_DEVICE; id++) { + for (uint32 id = 0; id < MAX_GPIO_PINS; id++) { gGPIOInfo[id] = (gpio_info*)malloc(sizeof(gpio_info)); if (gGPIOInfo[id] == NULL) @@ -225,10 +225,11 @@ uninit_common(void) } } - for (uint32 id = 0; id < ATOM_MAX_SUPPORTED_DEVICE; id++) { + for (uint32 id = 0; id < ATOM_MAX_SUPPORTED_DEVICE; id++) free(gConnector[id]); + + for (uint32 id = 0; id < MAX_GPIO_PINS; id++) free(gGPIOInfo[id]); - } }