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
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ extension SentryKSCrash {
/// - Throws: Any error from `KSCrash.installWithConfiguration(_:error:)`.
func install(
installPath: String,
monitors: UInt,
monitors: MonitorType,
enableMemoryIntrospection: Bool,
enableSwapCxaThrow: Bool
) throws
Expand Down Expand Up @@ -53,13 +53,13 @@ extension SentryKSCrash {

func install(
installPath: String,
monitors: UInt,
monitors: MonitorType,
enableMemoryIntrospection: Bool,
enableSwapCxaThrow: Bool
) throws {
let config = KSCrashConfiguration()
config.installPath = installPath
config.monitors = MonitorType(rawValue: monitors)
config.monitors = monitors
config.enableMemoryIntrospection = enableMemoryIntrospection
config.enableSwapCxaThrow = enableSwapCxaThrow
config.reportStoreConfiguration.reportCleanupPolicy = .onSuccess
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@ extension SentryKSCrash {
/// Mach exceptions, signals, C++ exceptions, and NSExceptions.
/// KSCrash unconditionally adds its required infrastructure monitors on top of
/// the crash detectors passed here.
static let productionSafeMonitors: UInt = MonitorType([
static let productionSafeMonitors: MonitorType = [
.machException,
.signal,
.cppException,
.nsException
]).rawValue
]

final class Integration<Dependencies: DependencyProvider>: NSObject, SwiftIntegration {
private weak var options: Options?
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#if SDK_V10
@_spi(Private) import SentryTestUtils
@_spi(Private) @testable import Sentry
internal import KSCrashRecording

final class MockKSCrashDependencies: SentryKSCrash.DependencyProvider {
typealias Installing = MockKSCrashInstaller
Expand Down Expand Up @@ -32,7 +33,7 @@ final class MockKSCrashInstaller: SentryKSCrash.Installing {
public var installCalls: [
(
installPath: String,
monitors: UInt,
monitors: MonitorType,
enableMemoryIntrospection: Bool,
enableSwapCxaThrow: Bool
)
Expand All @@ -52,7 +53,7 @@ final class MockKSCrashInstaller: SentryKSCrash.Installing {

public func install(
installPath: String,
monitors: UInt,
monitors: MonitorType,
enableMemoryIntrospection: Bool,
enableSwapCxaThrow: Bool
) throws {
Expand Down
Loading