diff --git a/GPU/Common/PresentationCommon.cpp b/GPU/Common/PresentationCommon.cpp index 4336773cde..102dfbb822 100644 --- a/GPU/Common/PresentationCommon.cpp +++ b/GPU/Common/PresentationCommon.cpp @@ -204,7 +204,7 @@ static std::string ReadShaderSrc(const std::string &filename) { return ""; std::string src(data, sz); - free(data); + delete[] data; return src; } diff --git a/GPU/Vulkan/TextureCacheVulkan.cpp b/GPU/Vulkan/TextureCacheVulkan.cpp index cf3f6d1758..7559db10d4 100644 --- a/GPU/Vulkan/TextureCacheVulkan.cpp +++ b/GPU/Vulkan/TextureCacheVulkan.cpp @@ -383,7 +383,7 @@ static std::string ReadShaderSrc(const std::string &filename) { return ""; std::string src(data, sz); - free(data); + delete[] data; return src; }