57
57
58
58
#pragma mark - API
59
59
void FIRCLSExceptionInitialize (FIRCLSExceptionReadOnlyContext *roContext,
60
- FIRCLSExceptionWritableContext *rwContext,
61
- void *delegate) {
60
+ FIRCLSExceptionWritableContext *rwContext) {
62
61
if (!FIRCLSUnlinkIfExists (roContext->path )) {
63
62
FIRCLSSDKLog (" Unable to reset the exception file %s\n " , strerror (errno));
64
63
}
@@ -82,8 +81,7 @@ void FIRCLSExceptionRecordModel(FIRExceptionModel *exceptionModel) {
82
81
const char *name = [[exceptionModel.name copy ] UTF8String ];
83
82
const char *reason = [[exceptionModel.reason copy ] UTF8String ] ?: " " ;
84
83
85
- FIRCLSExceptionRecord (FIRCLSExceptionTypeCustom, name, reason, [exceptionModel.stackTrace copy ],
86
- NO );
84
+ FIRCLSExceptionRecord (FIRCLSExceptionTypeCustom, name, reason, [exceptionModel.stackTrace copy ]);
87
85
}
88
86
89
87
void FIRCLSExceptionRecordNSException (NSException *exception) {
@@ -107,7 +105,7 @@ void FIRCLSExceptionRecordNSException(NSException *exception) {
107
105
}
108
106
109
107
FIRCLSExceptionRecord (FIRCLSExceptionTypeObjectiveC, [name UTF8String ], [reason UTF8String ],
110
- frames, YES );
108
+ frames);
111
109
}
112
110
113
111
static void FIRCLSExceptionRecordFrame (FIRCLSFile *file, FIRStackFrame *frame) {
@@ -189,15 +187,14 @@ void FIRCLSExceptionWrite(FIRCLSFile *file,
189
187
void FIRCLSExceptionRecord (FIRCLSExceptionType type,
190
188
const char *name,
191
189
const char *reason,
192
- NSArray <FIRStackFrame *> *frames,
193
- BOOL attemptDelivery) {
190
+ NSArray <FIRStackFrame *> *frames) {
194
191
if (!FIRCLSContextIsInitialized ()) {
195
192
return ;
196
193
}
197
194
198
195
bool native = FIRCLSExceptionIsNative (type);
199
196
200
- FIRCLSSDKLog (" Recording an exception structure (%d, %d )\n " , attemptDelivery , native);
197
+ FIRCLSSDKLog (" Recording an exception structure (%d)\n " , native);
201
198
202
199
// exceptions can happen on multiple threads at the same time
203
200
if (native) {
@@ -218,9 +215,6 @@ void FIRCLSExceptionRecord(FIRCLSExceptionType type,
218
215
FIRCLSFileClose (&file);
219
216
220
217
// disallow immediate delivery for non-native exceptions
221
- if (attemptDelivery) {
222
- FIRCLSHandlerAttemptImmediateDelivery ();
223
- }
224
218
});
225
219
} else {
226
220
FIRCLSUserLoggingWriteAndCheckABFiles (
@@ -278,21 +272,19 @@ static void FIRCLSCatchAndRecordActiveException(std::type_info *typeInfo) {
278
272
#endif
279
273
}
280
274
} catch (const char *exc) {
281
- FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, " const char *" , exc, nil , YES );
275
+ FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, " const char *" , exc, nil );
282
276
} catch (const std::string &exc) {
283
- FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, " std::string" , exc.c_str (), nil , YES );
277
+ FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, " std::string" , exc.c_str (), nil );
284
278
} catch (const std::exception &exc) {
285
- FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, FIRCLSExceptionDemangle (name), exc.what (), nil ,
286
- YES );
279
+ FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, FIRCLSExceptionDemangle (name), exc.what (), nil );
287
280
} catch (const std::exception *exc) {
288
- FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, FIRCLSExceptionDemangle (name), exc->what (), nil ,
289
- YES );
281
+ FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, FIRCLSExceptionDemangle (name), exc->what (), nil );
290
282
} catch (const std::bad_alloc &exc) {
291
283
// it is especially important to avoid demangling in this case, because the expetation at this
292
284
// point is that all allocations could fail
293
- FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, " std::bad_alloc" , exc.what (), nil , YES );
285
+ FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, " std::bad_alloc" , exc.what (), nil );
294
286
} catch (...) {
295
- FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, FIRCLSExceptionDemangle (name), " " , nil , YES );
287
+ FIRCLSExceptionRecord (FIRCLSExceptionTypeCpp, FIRCLSExceptionDemangle (name), " " , nil );
296
288
}
297
289
}
298
290
0 commit comments