#include "wx/imagtga.h"
#include "wx/log.h"
+#include "wx/scopeguard.h"
// ----------------------------------------------------------------------------
// constants
return wxTGA_MEMERR;
}
+ wxON_BLOCK_EXIT1(free, imageData);
+
unsigned char *dst = image->GetData();
unsigned char* alpha = NULL;
return wxTGA_INVFORMAT;
}
- free(imageData);
-
return wxTGA_OK;
}