mirror of
https://github.com/isledecomp/isle.git
synced 2025-10-22 16:04:17 +00:00
Fix wrong deletes in MxBitmap (#1482)
This commit is contained in:

committed by
GitHub

parent
934d90fc96
commit
396bf6b562
@@ -80,7 +80,7 @@ MxResult MxBitmap::SetSize(MxS32 p_width, MxS32 p_height, MxPalette* p_palette,
|
||||
done:
|
||||
if (ret) {
|
||||
if (m_info) {
|
||||
delete[] m_info;
|
||||
delete[] ((MxU8*) m_info);
|
||||
m_info = NULL;
|
||||
}
|
||||
|
||||
@@ -118,7 +118,7 @@ MxResult MxBitmap::ImportBitmapInfo(MxBITMAPINFO* p_info)
|
||||
done:
|
||||
if (result != SUCCESS) {
|
||||
if (m_info) {
|
||||
delete[] m_info;
|
||||
delete[] ((MxU8*) m_info);
|
||||
m_info = NULL;
|
||||
}
|
||||
|
||||
@@ -157,7 +157,7 @@ MxResult MxBitmap::ImportBitmap(MxBitmap* p_bitmap)
|
||||
done:
|
||||
if (result != SUCCESS) {
|
||||
if (m_info) {
|
||||
delete[] m_info;
|
||||
delete[] ((MxU8*) m_info);
|
||||
m_info = NULL;
|
||||
}
|
||||
|
||||
@@ -249,7 +249,7 @@ MxResult MxBitmap::LoadFile(HANDLE p_handle)
|
||||
done:
|
||||
if (result != SUCCESS) {
|
||||
if (m_info) {
|
||||
delete[] m_info;
|
||||
delete[] ((MxU8*) m_info);
|
||||
m_info = NULL;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user