From 95bb105817969dd90924ec6c27daf975719dcf8d Mon Sep 17 00:00:00 2001 From: Joshua Peisach Date: Sun, 13 Aug 2023 19:30:19 -0400 Subject: [PATCH] likely malloc is an operator new --- LEGO1/mxbitmap.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/LEGO1/mxbitmap.cpp b/LEGO1/mxbitmap.cpp index d80462cc..17a54996 100644 --- a/LEGO1/mxbitmap.cpp +++ b/LEGO1/mxbitmap.cpp @@ -105,7 +105,7 @@ MxResult MxBitmap::LoadFile(HANDLE p_handle) ret = ReadFile(p_handle, &hdr, sizeof(hdr), &bytesRead, NULL); if (ret && (hdr.bfType == g_bitmapSignature)) { - this->m_info = (BITMAPINFO*) malloc(1064); + this->m_info = new BITMAPINFO; if(this->m_info) { ret = ReadFile(p_handle, this->m_info, 1064, &bytesRead, NULL); if (ret && ((this->m_info->bmiHeader).biBitCount == 8)) {