Fix mismatching delete in IFF image handler code
Use delete[] for a buffer allocated with new[]. Closes https://github.com/wxWidgets/wxWidgets/pull/1684
This commit is contained in:
committed by
Vadim Zeitlin
parent
9689bd124e
commit
3b52ed60bb
@@ -414,7 +414,7 @@ int wxIFFDecoder::ReadIFF()
|
||||
const byte *cmapptr = dataptr + 8;
|
||||
colors = chunkLen / 3; // calc no of colors
|
||||
|
||||
wxDELETE(m_image->pal);
|
||||
wxDELETEA(m_image->pal);
|
||||
m_image->colors = colors;
|
||||
if (colors > 0) {
|
||||
m_image->pal = new byte[3*colors];
|
||||
|
||||
Reference in New Issue
Block a user