mirror of
https://github.com/VincentWei/MiniGUI.git
synced 2026-02-08 20:03:04 +08:00
use mg_slice_delete instead of free for CURSOR objects
This commit is contained in:
@@ -144,7 +144,7 @@ error:
|
||||
tempcsr = ((PG_RES)mgSharedRes)->sys_cursors[i];
|
||||
if (tempcsr) {
|
||||
GAL_FreeCursorSurface (tempcsr->surface);
|
||||
free (tempcsr);
|
||||
mg_slice_delete (CURSOR, tempcsr);
|
||||
((PG_RES)mgSharedRes)->sys_cursors[i] = NULL;
|
||||
}
|
||||
}
|
||||
@@ -203,7 +203,7 @@ static BOOL LoadCursorRes (void)
|
||||
temp += __mg_csrimgsize;
|
||||
free (tempcsr->AndBits);
|
||||
free (tempcsr->XorBits);
|
||||
free (tempcsr);
|
||||
mg_slice_delete (CURSOR, tempcsr);
|
||||
}
|
||||
|
||||
mgSizeRes += (sizeof (HCURSOR) + sizeof(CURSOR) + 2 * __mg_csrimgsize) * number;
|
||||
|
||||
Reference in New Issue
Block a user