diff --git a/Sources/KSCrashRecording/KSCrashReport.h b/Sources/KSCrashRecording/KSCrashReport.h index 941433939..0d17a2cbf 100644 --- a/Sources/KSCrashRecording/KSCrashReport.h +++ b/Sources/KSCrashRecording/KSCrashReport.h @@ -32,15 +32,14 @@ #ifndef HDR_KSCrashReport_h #define HDR_KSCrashReport_h -#ifdef __cplusplus -extern "C" { -#endif - #import "KSCrashReportWriter.h" #import "KSCrashMonitorContext.h" #include +#ifdef __cplusplus +extern "C" { +#endif // ============================================================================ #pragma mark - Configuration - diff --git a/Sources/KSCrashRecording/KSCrashReportStore.h b/Sources/KSCrashRecording/KSCrashReportStore.h index 185c9b225..b0ac7e4c0 100644 --- a/Sources/KSCrashRecording/KSCrashReportStore.h +++ b/Sources/KSCrashRecording/KSCrashReportStore.h @@ -27,13 +27,12 @@ #ifndef HDR_KSCrashReportStore_h #define HDR_KSCrashReportStore_h +#include + #ifdef __cplusplus extern "C" { #endif - -#include - #define KSCRS_MAX_PATH_LENGTH 500 /** Initialize the report store. diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitor.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitor.h index 9ff073683..1212e0f7e 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitor.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitor.h @@ -32,16 +32,15 @@ #ifndef HDR_KSCrashMonitor_h #define HDR_KSCrashMonitor_h -#ifdef __cplusplus -extern "C" { -#endif - - #include "KSCrashMonitorType.h" #include "KSThread.h" #include +#ifdef __cplusplus +extern "C" { +#endif + struct KSCrash_MonitorContext; diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitorContext.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitorContext.h index 4dc6ce2ca..b544d268e 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitorContext.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitorContext.h @@ -28,16 +28,16 @@ #ifndef HDR_KSCrashMonitorContext_h #define HDR_KSCrashMonitorContext_h -#ifdef __cplusplus -extern "C" { -#endif - #include "KSCrashMonitorType.h" #include "KSMachineContext.h" #include #include +#ifdef __cplusplus +extern "C" { +#endif + typedef struct KSCrash_MonitorContext { /** Unique identifier for this event. */ diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_AppState.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_AppState.h index 54c95604d..4ccaeb37f 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_AppState.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_AppState.h @@ -33,14 +33,13 @@ #ifndef HDR_KSCrashMonitor_AppState_h #define HDR_KSCrashMonitor_AppState_h -#ifdef __cplusplus -extern "C" { -#endif - #include "KSCrashMonitor.h" #include +#ifdef __cplusplus +extern "C" { +#endif typedef struct { diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_CPPException.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_CPPException.h index d599d74ca..bbb9287a0 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_CPPException.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_CPPException.h @@ -25,12 +25,12 @@ #ifndef HDR_KSCrashMonitor_CPPException_h #define HDR_KSCrashMonitor_CPPException_h +#include "KSCrashMonitor.h" + #ifdef __cplusplus extern "C" { #endif -#include "KSCrashMonitor.h" - /** Enable swapping of __cxa_trow symbol with lazy symbols table */ void kscm_enableSwapCxaThrow(void); diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_MachException.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_MachException.h index 883166be2..204f25922 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_MachException.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_MachException.h @@ -32,13 +32,13 @@ #ifndef HDR_KSCrashMonitor_MachException_h #define HDR_KSCrashMonitor_MachException_h +#include "KSCrashMonitor.h" +#include + #ifdef __cplusplus extern "C" { #endif -#include "KSCrashMonitor.h" -#include - /** Access the Monitor API. */ diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_NSException.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_NSException.h index e30cbbd07..ec166dd1d 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_NSException.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_NSException.h @@ -32,14 +32,13 @@ #ifndef HDR_KSCrashMonitor_NSException_h #define HDR_KSCrashMonitor_NSException_h +#include "KSCrashMonitor.h" + #ifdef __cplusplus extern "C" { #endif -#include "KSCrashMonitor.h" - - /** Access the Monitor API. */ KSCrashMonitorAPI* kscm_nsexception_getAPI(void); diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_Signal.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_Signal.h index 13a6f8058..bf3e76da4 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_Signal.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_Signal.h @@ -32,14 +32,13 @@ #ifndef HDR_KSCrashMonitor_Signal_h #define HDR_KSCrashMonitor_Signal_h +#include "KSCrashMonitor.h" + #ifdef __cplusplus extern "C" { #endif -#include "KSCrashMonitor.h" - - /** Access the Monitor API. */ KSCrashMonitorAPI* kscm_signal_getAPI(void); diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_System.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_System.h index 54407f961..6dd47ee67 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_System.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_System.h @@ -27,14 +27,13 @@ #ifndef KSCrashMonitor_System_h #define KSCrashMonitor_System_h +#include "KSCrashMonitor.h" + #ifdef __cplusplus extern "C" { #endif -#include "KSCrashMonitor.h" - - /** Access the Monitor API. */ KSCrashMonitorAPI* kscm_system_getAPI(void); diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_User.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_User.h index d7b64a7fa..35344465f 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_User.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_User.h @@ -25,15 +25,14 @@ #ifndef HDR_KSCrashMonitor_User_h #define HDR_KSCrashMonitor_User_h -#ifdef __cplusplus -extern "C" { -#endif - - #include "KSCrashMonitor.h" #include +#ifdef __cplusplus +extern "C" { +#endif + /** Report a custom, user defined exception. * If terminateProgram is true, all sentries will be uninstalled and the application will diff --git a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_Zombie.h b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_Zombie.h index 0356ba78d..da43a6a56 100644 --- a/Sources/KSCrashRecording/Monitors/KSCrashMonitor_Zombie.h +++ b/Sources/KSCrashRecording/Monitors/KSCrashMonitor_Zombie.h @@ -41,13 +41,12 @@ #ifndef HDR_KSZombie_h #define HDR_KSZombie_h -#ifdef __cplusplus -extern "C" { -#endif - #include "KSCrashMonitor.h" #include +#ifdef __cplusplus +extern "C" { +#endif /** Get the class of a deallocated object pointer, if it was tracked. * diff --git a/Sources/KSCrashRecording/include/KSCrashC.h b/Sources/KSCrashRecording/include/KSCrashC.h index f09fb32f0..4b51d3ada 100644 --- a/Sources/KSCrashRecording/include/KSCrashC.h +++ b/Sources/KSCrashRecording/include/KSCrashC.h @@ -32,16 +32,14 @@ #ifndef HDR_KSCrashC_h #define HDR_KSCrashC_h -#ifdef __cplusplus -extern "C" { -#endif - - #include "KSCrashMonitorType.h" #include "KSCrashReportWriter.h" #include +#ifdef __cplusplus +extern "C" { +#endif /** Install the crash reporter. The reporter will record the next crash and then * terminate the program. diff --git a/Sources/KSCrashRecording/include/KSCrashReportWriter.h b/Sources/KSCrashRecording/include/KSCrashReportWriter.h index 8f11a9573..782bb33e3 100644 --- a/Sources/KSCrashRecording/include/KSCrashReportWriter.h +++ b/Sources/KSCrashRecording/include/KSCrashReportWriter.h @@ -33,14 +33,12 @@ #ifndef HDR_KSCrashReportWriter_h #define HDR_KSCrashReportWriter_h -#ifdef __cplusplus -extern "C" { -#endif - - #include #include +#ifdef __cplusplus +extern "C" { +#endif /** * Encapsulates report writing functionality. diff --git a/Sources/KSCrashRecordingCore/include/KSCPU.h b/Sources/KSCrashRecordingCore/include/KSCPU.h index f28269ccf..1023670fe 100644 --- a/Sources/KSCrashRecordingCore/include/KSCPU.h +++ b/Sources/KSCrashRecordingCore/include/KSCPU.h @@ -27,16 +27,15 @@ #ifndef HDR_KSCPU_h #define HDR_KSCPU_h -#ifdef __cplusplus -extern "C" { -#endif - - #include "KSMachineContext.h" #include #include +#ifdef __cplusplus +extern "C" { +#endif + /** Get the current CPU architecture. * * @return The current architecture. diff --git a/Sources/KSCrashRecordingCore/include/KSCPU_Apple.h b/Sources/KSCrashRecordingCore/include/KSCPU_Apple.h index 1b1bbadca..e74e8f557 100644 --- a/Sources/KSCrashRecordingCore/include/KSCPU_Apple.h +++ b/Sources/KSCrashRecordingCore/include/KSCPU_Apple.h @@ -27,13 +27,12 @@ #ifndef HDR_KSCPU_Apple_h #define HDR_KSCPU_Apple_h +#include + #ifdef __cplusplus extern "C" { #endif - -#include - /** Fill in state information about a thread. * * @param thread The thread to get information about. diff --git a/Sources/KSCrashRecordingCore/include/KSDate.h b/Sources/KSCrashRecordingCore/include/KSDate.h index bcf06bab7..c08b5ed86 100644 --- a/Sources/KSCrashRecordingCore/include/KSDate.h +++ b/Sources/KSCrashRecordingCore/include/KSDate.h @@ -25,13 +25,12 @@ #ifndef KSDate_h #define KSDate_h +#include + #ifdef __cplusplus extern "C" { #endif - -#include - /** Convert a UNIX timestamp to an RFC3339 string representation. * * @param timestamp The date to convert. diff --git a/Sources/KSCrashRecordingCore/include/KSDebug.h b/Sources/KSCrashRecordingCore/include/KSDebug.h index 16d5a66a7..233444865 100644 --- a/Sources/KSCrashRecordingCore/include/KSDebug.h +++ b/Sources/KSCrashRecordingCore/include/KSDebug.h @@ -31,15 +31,13 @@ #ifndef HDR_KSDebug_h #define HDR_KSDebug_h + +#include #ifdef __cplusplus extern "C" { #endif - -#include - - /** Check if the current process is being traced or not. * * @return true if we're being traced. diff --git a/Sources/KSCrashRecordingCore/include/KSDynamicLinker.h b/Sources/KSCrashRecordingCore/include/KSDynamicLinker.h index 4c87307d6..8161b2cb4 100644 --- a/Sources/KSCrashRecordingCore/include/KSDynamicLinker.h +++ b/Sources/KSCrashRecordingCore/include/KSDynamicLinker.h @@ -27,15 +27,14 @@ #ifndef HDR_KSDynamicLinker_h #define HDR_KSDynamicLinker_h -#ifdef __cplusplus -extern "C" { -#endif - - #include #include #include +#ifdef __cplusplus +extern "C" { +#endif + typedef struct { uint64_t address; diff --git a/Sources/KSCrashRecordingCore/include/KSFileUtils.h b/Sources/KSCrashRecordingCore/include/KSFileUtils.h index 26d4a7f27..a5f49fbbe 100644 --- a/Sources/KSCrashRecordingCore/include/KSFileUtils.h +++ b/Sources/KSCrashRecordingCore/include/KSFileUtils.h @@ -32,14 +32,12 @@ #ifndef HDR_KSFileUtils_h #define HDR_KSFileUtils_h -#ifdef __cplusplus -extern "C" { -#endif - - #include #include +#ifdef __cplusplus +extern "C" { +#endif #define KSFU_MAX_PATH_LENGTH 500 diff --git a/Sources/KSCrashRecordingCore/include/KSJSONCodec.h b/Sources/KSCrashRecordingCore/include/KSJSONCodec.h index d56bb7ca0..f41503f56 100644 --- a/Sources/KSCrashRecordingCore/include/KSJSONCodec.h +++ b/Sources/KSCrashRecordingCore/include/KSJSONCodec.h @@ -32,14 +32,13 @@ #ifndef HDR_KSJSONCodec_h #define HDR_KSJSONCodec_h +#include +#include + #ifdef __cplusplus extern "C" { #endif - -#include -#include - /* Tells the encoder to automatically determine the length of a field value. * Currently, this is done using strlen(). */ diff --git a/Sources/KSCrashRecordingCore/include/KSLogger.h b/Sources/KSCrashRecordingCore/include/KSLogger.h index 7b7b55d7c..185d5a334 100644 --- a/Sources/KSCrashRecordingCore/include/KSLogger.h +++ b/Sources/KSCrashRecordingCore/include/KSLogger.h @@ -147,14 +147,12 @@ #ifndef HDR_KSLogger_h #define HDR_KSLogger_h +#include + #ifdef __cplusplus extern "C" { #endif - -#include - - #ifdef __OBJC__ #import diff --git a/Sources/KSCrashRecordingCore/include/KSMach.h b/Sources/KSCrashRecordingCore/include/KSMach.h index 34c0e566c..29c774218 100644 --- a/Sources/KSCrashRecordingCore/include/KSMach.h +++ b/Sources/KSCrashRecordingCore/include/KSMach.h @@ -25,13 +25,12 @@ #ifndef HDR_KSMach_h #define HDR_KSMach_h +#include + #ifdef __cplusplus extern "C" { #endif - -#include - /** Get the name of a mach exception. * * @param exceptionType The exception type. diff --git a/Sources/KSCrashRecordingCore/include/KSMachineContext.h b/Sources/KSCrashRecordingCore/include/KSMachineContext.h index 35208c04a..7ee8f69d9 100644 --- a/Sources/KSCrashRecordingCore/include/KSMachineContext.h +++ b/Sources/KSCrashRecordingCore/include/KSMachineContext.h @@ -28,14 +28,14 @@ #ifndef HDR_KSMachineContext_h #define HDR_KSMachineContext_h -#ifdef __cplusplus -extern "C" { -#endif - #include "KSThread.h" #include #include +#ifdef __cplusplus +extern "C" { +#endif + /** Suspend the runtime environment. */ void ksmc_suspendEnvironment(thread_act_array_t *suspendedThreads, mach_msg_type_number_t *numSuspendedThreads); diff --git a/Sources/KSCrashRecordingCore/include/KSMachineContext_Apple.h b/Sources/KSCrashRecordingCore/include/KSMachineContext_Apple.h index 76a1bb76e..094e24c80 100644 --- a/Sources/KSCrashRecordingCore/include/KSMachineContext_Apple.h +++ b/Sources/KSCrashRecordingCore/include/KSMachineContext_Apple.h @@ -28,14 +28,14 @@ #ifndef HDR_KSMachineContext_Apple_h #define HDR_KSMachineContext_Apple_h -#ifdef __cplusplus -extern "C" { -#endif - #include #include #include +#ifdef __cplusplus +extern "C" { +#endif + #ifdef __arm64__ #define STRUCT_MCONTEXT_L _STRUCT_MCONTEXT64 #else diff --git a/Sources/KSCrashRecordingCore/include/KSMemory.h b/Sources/KSCrashRecordingCore/include/KSMemory.h index ae4e9e2e7..62c5d9c76 100644 --- a/Sources/KSCrashRecordingCore/include/KSMemory.h +++ b/Sources/KSCrashRecordingCore/include/KSMemory.h @@ -32,14 +32,12 @@ #ifndef HDR_ksmemory_h #define HDR_ksmemory_h +#include + #ifdef __cplusplus extern "C" { #endif - -#include - - /** Test if the specified memory is safe to read from. * * @param memory A pointer to the memory to test. diff --git a/Sources/KSCrashRecordingCore/include/KSObjC.h b/Sources/KSCrashRecordingCore/include/KSObjC.h index 18255ff45..27da028d9 100644 --- a/Sources/KSCrashRecordingCore/include/KSObjC.h +++ b/Sources/KSCrashRecordingCore/include/KSObjC.h @@ -28,14 +28,12 @@ #ifndef HDR_KSObjC_h #define HDR_KSObjC_h -#ifdef __cplusplus -extern "C" { -#endif - - #include #include +#ifdef __cplusplus +extern "C" { +#endif typedef enum { diff --git a/Sources/KSCrashRecordingCore/include/KSObjCApple.h b/Sources/KSCrashRecordingCore/include/KSObjCApple.h index 4e99c3fef..5a92c2328 100644 --- a/Sources/KSCrashRecordingCore/include/KSObjCApple.h +++ b/Sources/KSCrashRecordingCore/include/KSObjCApple.h @@ -19,14 +19,12 @@ #ifndef HDR_KSObjCApple_h #define HDR_KSObjCApple_h -#ifdef __cplusplus -extern "C" { -#endif - - #include #include +#ifdef __cplusplus +extern "C" { +#endif #define MAKE_LIST_T(TYPE) \ typedef struct TYPE##_list_t { \ diff --git a/Sources/KSCrashRecordingCore/include/KSSignalInfo.h b/Sources/KSCrashRecordingCore/include/KSSignalInfo.h index 8a98fe4f3..6ed78841b 100644 --- a/Sources/KSCrashRecordingCore/include/KSSignalInfo.h +++ b/Sources/KSCrashRecordingCore/include/KSSignalInfo.h @@ -32,14 +32,12 @@ #ifndef HDR_KSSignalInfo_h #define HDR_KSSignalInfo_h +#include + #ifdef __cplusplus extern "C" { #endif - -#include - - /** Get the name of a signal. * * @param signal The signal. diff --git a/Sources/KSCrashRecordingCore/include/KSStackCursor.h b/Sources/KSCrashRecordingCore/include/KSStackCursor.h index d96028087..d634d57ae 100644 --- a/Sources/KSCrashRecordingCore/include/KSStackCursor.h +++ b/Sources/KSCrashRecordingCore/include/KSStackCursor.h @@ -25,17 +25,16 @@ #ifndef KSStackCursor_h #define KSStackCursor_h - -#ifdef __cplusplus -extern "C" { -#endif - #include "KSMachineContext.h" #include #include +#ifdef __cplusplus +extern "C" { +#endif + #define KSSC_CONTEXT_SIZE 100 /** Point at which to give up walking a stack and consider it a stack overflow. */ diff --git a/Sources/KSCrashRecordingCore/include/KSStackCursor_Backtrace.h b/Sources/KSCrashRecordingCore/include/KSStackCursor_Backtrace.h index 32436e641..c89a7ddee 100644 --- a/Sources/KSCrashRecordingCore/include/KSStackCursor_Backtrace.h +++ b/Sources/KSCrashRecordingCore/include/KSStackCursor_Backtrace.h @@ -25,13 +25,12 @@ #ifndef KSStackCursor_Backtrace_h #define KSStackCursor_Backtrace_h + +#include "KSStackCursor.h" #ifdef __cplusplus extern "C" { #endif - - -#include "KSStackCursor.h" /** Exposed for other internal systems to use. */ diff --git a/Sources/KSCrashRecordingCore/include/KSStackCursor_MachineContext.h b/Sources/KSCrashRecordingCore/include/KSStackCursor_MachineContext.h index db2dc06e9..531db2ae7 100644 --- a/Sources/KSCrashRecordingCore/include/KSStackCursor_MachineContext.h +++ b/Sources/KSCrashRecordingCore/include/KSStackCursor_MachineContext.h @@ -25,13 +25,12 @@ #ifndef KSStackCursor_MachineContext_h #define KSStackCursor_MachineContext_h + +#include "KSStackCursor.h" #ifdef __cplusplus extern "C" { #endif - - -#include "KSStackCursor.h" /** Initialize a stack cursor for a machine context. * diff --git a/Sources/KSCrashRecordingCore/include/KSStackCursor_SelfThread.h b/Sources/KSCrashRecordingCore/include/KSStackCursor_SelfThread.h index 99e313145..20405ec8f 100644 --- a/Sources/KSCrashRecordingCore/include/KSStackCursor_SelfThread.h +++ b/Sources/KSCrashRecordingCore/include/KSStackCursor_SelfThread.h @@ -25,13 +25,12 @@ #ifndef KSStackCursor_SelfThread_h #define KSStackCursor_SelfThread_h + +#include "KSStackCursor.h" #ifdef __cplusplus extern "C" { #endif - - -#include "KSStackCursor.h" /** Initialize a stack cursor for the current thread. * You may want to skip some entries to account for the trace immediately leading diff --git a/Sources/KSCrashRecordingCore/include/KSString.h b/Sources/KSCrashRecordingCore/include/KSString.h index f0c2b8396..64d355fa2 100644 --- a/Sources/KSCrashRecordingCore/include/KSString.h +++ b/Sources/KSCrashRecordingCore/include/KSString.h @@ -27,14 +27,12 @@ #ifndef HDR_KSString_h #define HDR_KSString_h -#ifdef __cplusplus -extern "C" { -#endif - - #include #include +#ifdef __cplusplus +extern "C" { +#endif /** Check if a memory location contains a null terminated UTF-8 string. * diff --git a/Sources/KSCrashRecordingCore/include/KSSymbolicator.h b/Sources/KSCrashRecordingCore/include/KSSymbolicator.h index db83f2350..cc0614752 100644 --- a/Sources/KSCrashRecordingCore/include/KSSymbolicator.h +++ b/Sources/KSCrashRecordingCore/include/KSSymbolicator.h @@ -26,14 +26,13 @@ #ifndef KSSymbolicator_h #define KSSymbolicator_h +#include "KSStackCursor.h" +#include + #ifdef __cplusplus extern "C" { #endif - -#include "KSStackCursor.h" -#include - /** Call instruction address is different from return address. * * @param returnAddress The return address of fuction call. diff --git a/Sources/KSCrashRecordingCore/include/KSSysCtl.h b/Sources/KSCrashRecordingCore/include/KSSysCtl.h index 1d56321ac..b819df49e 100644 --- a/Sources/KSCrashRecordingCore/include/KSSysCtl.h +++ b/Sources/KSCrashRecordingCore/include/KSSysCtl.h @@ -32,15 +32,13 @@ #ifndef HDR_KSSysCtl_h #define HDR_KSSysCtl_h -#ifdef __cplusplus -extern "C" { -#endif - - #include #include #include +#ifdef __cplusplus +extern "C" { +#endif /** Get an int32 value via sysctl. * diff --git a/Sources/KSCrashRecordingCore/include/KSThread.h b/Sources/KSCrashRecordingCore/include/KSThread.h index 74225fea8..3a4bbc3ff 100644 --- a/Sources/KSCrashRecordingCore/include/KSThread.h +++ b/Sources/KSCrashRecordingCore/include/KSThread.h @@ -27,14 +27,12 @@ #ifndef HDR_KSThread_h #define HDR_KSThread_h -#ifdef __cplusplus -extern "C" { -#endif - - #include #include +#ifdef __cplusplus +extern "C" { +#endif typedef uintptr_t KSThread; diff --git a/Sources/KSCrashRecordingCore/include/KSgetsect.h b/Sources/KSCrashRecordingCore/include/KSgetsect.h index 6140e0d59..7dc1505b3 100644 --- a/Sources/KSCrashRecordingCore/include/KSgetsect.h +++ b/Sources/KSCrashRecordingCore/include/KSgetsect.h @@ -25,13 +25,13 @@ #ifndef KSgetsect_h #define KSgetsect_h +#include +#include "KSPlatformSpecificDefines.h" + #ifdef __cplusplus extern "C" { #endif /* __cplusplus */ -#include -#include "KSPlatformSpecificDefines.h" - /** * This routine returns the segment_command structure for the named segment * if it exist in the passed mach header. Otherwise it returns zero.