Skip to content

Commit 792dd45

Browse files
committed
Remove "malloc.h" includes as they are no longer used
1 parent 44fb2f2 commit 792dd45

10 files changed

+2
-10
lines changed

source/d3d12/d3d12_command_list.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
#include "d3d12_descriptor_heap.hpp"
99
#include "d3d12_impl_type_convert.hpp"
1010
#include "dll_log.hpp"
11-
#include <malloc.h>
1211

1312
using reshade::d3d12::to_handle;
1413

source/d3d12/d3d12_command_queue.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
#include "d3d12_command_queue.hpp"
99
#include "d3d12_command_queue_downlevel.hpp"
1010
#include "dll_log.hpp"
11-
#include <malloc.h>
1211

1312
D3D12CommandQueue::D3D12CommandQueue(D3D12Device *device, ID3D12CommandQueue *original) :
1413
command_queue_impl(device, original),

source/d3d12/d3d12_device.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
#include "d3d12_impl_type_convert.hpp"
1212
#include "dll_log.hpp" // Include late to get HRESULT log overloads
1313
#include "com_utils.hpp"
14-
#include <malloc.h>
1514

1615
using reshade::d3d12::to_handle;
1716

source/d3d12/d3d12_impl_command_list.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
#include "d3d12_impl_device.hpp"
77
#include "d3d12_impl_command_list.hpp"
88
#include "d3d12_impl_type_convert.hpp"
9-
#include <malloc.h>
109
#include <algorithm>
1110

1211
void encode_pix3blob(UINT64(&pix3blob)[64], const char *label, const float color[4])

source/d3d12/d3d12_impl_device.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
#include "d3d12_descriptor_heap.hpp"
1010
#include "dll_log.hpp"
1111
#include "dll_resources.hpp"
12-
#include <malloc.h>
1312
#include <algorithm>
1413

1514
extern bool is_windows7();

source/opengl/opengl_hooks.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
#include "opengl_impl_swapchain.hpp"
88
#include "opengl_impl_type_convert.hpp"
99
#include "opengl_hooks.hpp" // Fix name clashes with gl3w
10-
#include <malloc.h>
1110

1211
struct DrawArraysIndirectCommand
1312
{
@@ -228,6 +227,7 @@ static reshade::api::subresource_data convert_mapped_subresource(GLenum format,
228227
return result;
229228
}
230229

230+
#if RESHADE_ADDON && !RESHADE_ADDON_LITE
231231
static bool copy_buffer_region(GLenum src_target, GLuint src_object, GLintptr src_offset, GLenum dst_target, GLuint dst_object, GLintptr dst_offset, GLsizeiptr size)
232232
{
233233
if (!g_current_context || !reshade::has_addon_event<reshade::addon_event::copy_buffer_region>())
@@ -355,6 +355,7 @@ static bool update_texture_region(GLenum target, GLuint object, GLint level, GLi
355355
std::vector<uint8_t> temp_data;
356356
return reshade::invoke_addon_event<reshade::addon_event::update_texture_region>(g_current_context, convert_mapped_subresource(format, type, pixels, &temp_data, width, height, depth), dst, subresource, &dst_box);
357357
}
358+
#endif
358359

359360
static __forceinline auto get_index_buffer_offset(const GLvoid *indices) -> GLuint
360361
{

source/vulkan/vulkan_hooks_cmd.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
#include "vulkan_impl_device.hpp"
99
#include "vulkan_impl_command_list.hpp"
1010
#include "vulkan_impl_type_convert.hpp"
11-
#include <malloc.h>
1211
#include <algorithm>
1312

1413
extern lockfree_linear_map<void *, reshade::vulkan::device_impl *, 8> g_vulkan_devices;

source/vulkan/vulkan_hooks_device.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
#include "vulkan_impl_command_queue.hpp"
1212
#include "vulkan_impl_swapchain.hpp"
1313
#include "vulkan_impl_type_convert.hpp"
14-
#include <malloc.h>
1514

1615
// Set during Vulkan device creation and presentation, to avoid hooking internal D3D devices created e.g. by NVIDIA Ansel and Optimus
1716
extern thread_local bool g_in_dxgi_runtime;

source/vulkan/vulkan_impl_command_list.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
#include "vulkan_impl_device.hpp"
77
#include "vulkan_impl_command_list.hpp"
88
#include "vulkan_impl_type_convert.hpp"
9-
#include <malloc.h>
109
#include <algorithm>
1110

1211
#define vk _device_impl->_dispatch_table

source/vulkan/vulkan_impl_device.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
#include "vulkan_impl_device.hpp"
88
#include "vulkan_impl_command_queue.hpp"
99
#include "vulkan_impl_type_convert.hpp"
10-
#include <malloc.h>
1110
#include <algorithm>
1211

1312
#define vk _dispatch_table

0 commit comments

Comments
 (0)