Skip to content

Commit e6ea16c

Browse files
committed
[Crashlytics] Sync signal/exception handler installation
1 parent 7e92305 commit e6ea16c

File tree

2 files changed

+12
-10
lines changed

2 files changed

+12
-10
lines changed

Crashlytics/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# Unreleased
2+
- [fixed] Installed Crashlytics signal and mach exception handlers synchronously to
3+
improve compatibility with other crash reporters and runtime environments (like
4+
Mono/Xamarin). (#15383)
5+
16
# 12.4.0
27
- [fixed] Make set development platform APIs to chain on Crashlytics context init promise.
38

Crashlytics/Crashlytics/Components/FIRCLSContext.m

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
12
// Copyright 2019 Google
23
//
34
// Licensed under the Apache License, Version 2.0 (the "License");
@@ -172,21 +173,17 @@
172173
// simulator to crash.
173174
if (!_firclsContext.readonly->debuggerAttached) {
174175
#if CLS_SIGNAL_SUPPORTED
175-
dispatch_group_async(group, queue, ^{
176-
_firclsContext.readonly->signal.path =
177-
FIRCLSContextAppendToRoot(rootPath, FIRCLSReportSignalFile);
176+
_firclsContext.readonly->signal.path =
177+
FIRCLSContextAppendToRoot(rootPath, FIRCLSReportSignalFile);
178178

179-
FIRCLSSignalInitialize(&_firclsContext.readonly->signal);
180-
});
179+
FIRCLSSignalInitialize(&_firclsContext.readonly->signal);
181180
#endif
182181

183182
#if CLS_MACH_EXCEPTION_SUPPORTED
184-
dispatch_group_async(group, queue, ^{
185-
_firclsContext.readonly->machException.path =
186-
FIRCLSContextAppendToRoot(rootPath, FIRCLSReportMachExceptionFile);
183+
_firclsContext.readonly->machException.path =
184+
FIRCLSContextAppendToRoot(rootPath, FIRCLSReportMachExceptionFile);
187185

188-
FIRCLSMachExceptionInit(&_firclsContext.readonly->machException);
189-
});
186+
FIRCLSMachExceptionInit(&_firclsContext.readonly->machException);
190187
#endif
191188

192189
dispatch_group_async(group, queue, ^{

0 commit comments

Comments
 (0)