Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/binary/object.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
#include "binary/module_base.hpp"

#include <string>
#include <system_error>
#include <vector>
#include <mutex>
#include <unordered_map>
Expand All @@ -16,7 +17,9 @@
#include <link.h> // needed for dladdr1's link_map info
#endif
#elif IS_WINDOWS
#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>
#endif

Expand Down
4 changes: 3 additions & 1 deletion src/binary/pe.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,9 @@
#include <cstring>
#include <string>

#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>

namespace cpptrace {
Expand Down
4 changes: 3 additions & 1 deletion src/demangle/demangle_with_winapi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@

#include <string>

#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>
#include <dbghelp.h>

Expand Down
4 changes: 3 additions & 1 deletion src/from_current.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
#ifndef _MSC_VER
#include <string.h>
#if IS_WINDOWS
#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>
#else
#include <sys/mman.h>
Expand Down
4 changes: 3 additions & 1 deletion src/platform/dbghelp_syminit_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@

#include <unordered_set>

#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>
#include <dbghelp.h>

Expand Down
4 changes: 3 additions & 1 deletion src/platform/path.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@
#include <cctype>

#if IS_WINDOWS
#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>
#endif

Expand Down
4 changes: 3 additions & 1 deletion src/platform/program_name.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@
#include "platform/platform.hpp"

#if IS_WINDOWS
#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>

#define CPPTRACE_MAX_PATH MAX_PATH
Expand Down
4 changes: 3 additions & 1 deletion src/symbols/symbols_with_dbghelp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@
#include <system_error>
#include <vector>

#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>
#include <dbghelp.h>

Expand Down
4 changes: 3 additions & 1 deletion src/unwind/unwind_with_winapi.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,9 @@
#include <cstdint>
#include <vector>

#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>

// Fucking windows headers
Expand Down
4 changes: 3 additions & 1 deletion src/utils/utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@

#if IS_WINDOWS
#include <io.h>
#define WIN32_LEAN_AND_MEAN
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
#include <windows.h>
#else
#include <sys/stat.h>
Expand Down
Loading