Description
Description
I’m encountering a crash in our app on iOS 18.3.2. The crash appears to occur in the GDTCORFlatFileStorage
module when trying to enumerate a directory. The crash log points to the following call in GDTCORFlatFileStorage.m
:
NSDirectoryEnumerator *enumerator = [fileManager enumeratorAtPath:targetPath];
It appears that during directory enumeration (likely when creating or accessing the directory based on [GDTCORFlatFileStorage eventDataStoragePath]
), an exception is thrown in the underlying file system calls (e.g., fstatat
, _mkpath
).
Could you please investigate if this is a known issue with iOS 18.3.2 or if there are recommended workarounds for this problem? Any guidance or patches to address this crash would be greatly appreciated.
Thank you for your help!
Reproducing the issue
Unfortunately, we have not been able to reproduce the crash in our development environment. The crash is observed in production, and appears to be triggered during directory creation/enumeration in GDTCORFlatFileStorage
.
Firebase SDK Version
10.29.0
Xcode Version
16.3
Installation Method
CocoaPods
Firebase Product(s)
Crashlytics
Targeted Platforms
iOS
Relevant Log Output
# Crashlytics - Stack trace
# Application:
# Platform: apple
com.apple.main-thread
0 libsystem_kernel.dylib 0x1788 mach_msg2_trap + 8
1 libsystem_kernel.dylib 0x4e98 mach_msg2_internal + 80
2 libsystem_kernel.dylib 0x4db0 mach_msg_overwrite + 424
3 libsystem_kernel.dylib 0x4bfc mach_msg + 24
4 CoreFoundation 0x76804 __CFRunLoopServiceMachPort + 160
5 CoreFoundation 0x75eb0 __CFRunLoopRun + 1212
6 CoreFoundation 0xc8284 CFRunLoopRunSpecific + 588
7 GraphicsServices 0x14c0 GSEventRunModal + 164
8 UIKitCore 0x3ee674 -[UIApplication _run] + 816
9 UIKitCore 0x14e88 UIApplicationMain + 340
10 APP 0x80a4 main + 35 (main.m:35)
11 ??? 0x1c8a01de8 (缺少)
Thread
0 libsystem_pthread.dylib 0x146c start_wqthread + 10
com.apple.uikit.eventfetch-thread
0 libsystem_kernel.dylib 0x1788 mach_msg2_trap + 8
1 libsystem_kernel.dylib 0x4e98 mach_msg2_internal + 80
2 libsystem_kernel.dylib 0x4db0 mach_msg_overwrite + 424
3 libsystem_kernel.dylib 0x4bfc mach_msg + 24
4 CoreFoundation 0x76804 __CFRunLoopServiceMachPort + 160
5 CoreFoundation 0x75eb0 __CFRunLoopRun + 1212
6 CoreFoundation 0xc8284 CFRunLoopRunSpecific + 588
7 Foundation 0x2a0e8 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
8 Foundation 0x186bb0 -[NSRunLoop(NSRunLoop) runUntilDate:] + 64
9 UIKitCore 0x481a78 -[UIEventFetcher threadMain] + 420
10 Foundation 0x115f30 __NSThread__start__ + 724
11 libsystem_pthread.dylib 0x17d0 _pthread_start + 136
12 libsystem_pthread.dylib 0x1480 thread_start + 8
com.google.firebase.crashlytics.MachExceptionServer
0 APP 0x5bb20 FIRCLSProcessRecordAllThreads + 392 (FIRCLSProcess.c:392)
1 APP 0x5bf04 FIRCLSProcessRecordAllThreads + 423 (FIRCLSProcess.c:423)
2 APP 0x5312c FIRCLSHandler + 34 (FIRCLSHandler.m:34)
3 APP 0x55a94 FIRCLSMachExceptionServer + 521 (FIRCLSMachException.c:521)
4 libsystem_pthread.dylib 0x17d0 _pthread_start + 136
5 libsystem_pthread.dylib 0x1480 thread_start + 8
Thread
0 libsystem_kernel.dylib 0x1510 __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x36cc _pthread_wqthread + 364
2 libsystem_pthread.dylib 0x1474 start_wqthread + 8
com.facebook.SocketRocket.NetworkThread
0 libsystem_kernel.dylib 0x1788 mach_msg2_trap + 8
1 libsystem_kernel.dylib 0x4e98 mach_msg2_internal + 80
2 libsystem_kernel.dylib 0x4db0 mach_msg_overwrite + 424
3 libsystem_kernel.dylib 0x4bfc mach_msg + 24
4 CoreFoundation 0x76804 __CFRunLoopServiceMachPort + 160
5 CoreFoundation 0x75eb0 __CFRunLoopRun + 1212
6 CoreFoundation 0xc8284 CFRunLoopRunSpecific + 588
7 Foundation 0x2a0e8 -[NSRunLoop(NSRunLoop) runMode:beforeDate:] + 212
8 APP 0x1b4abc -[SRRunLoopThread main] + 71 (SRRunLoopThread.m:71)
9 Foundation 0x115f30 __NSThread__start__ + 724
10 libsystem_pthread.dylib 0x17d0 _pthread_start + 136
11 libsystem_pthread.dylib 0x1480 thread_start + 8
com.apple.NSURLConnectionLoader
0 libsystem_kernel.dylib 0x1788 mach_msg2_trap + 8
1 libsystem_kernel.dylib 0x4e98 mach_msg2_internal + 80
2 libsystem_kernel.dylib 0x4db0 mach_msg_overwrite + 424
3 libsystem_kernel.dylib 0x4bfc mach_msg + 24
4 CoreFoundation 0x76804 __CFRunLoopServiceMachPort + 160
5 CoreFoundation 0x75eb0 __CFRunLoopRun + 1212
6 CoreFoundation 0xc8284 CFRunLoopRunSpecific + 588
7 CFNetwork 0xf1c4c +[__CFN_CoreSchedulingSetRunnable _run:] + 416
8 Foundation 0x115f30 __NSThread__start__ + 724
9 libsystem_pthread.dylib 0x17d0 _pthread_start + 136
10 libsystem_pthread.dylib 0x1480 thread_start + 8
com.apple.CFSocket.private
0 libsystem_kernel.dylib 0x9334 select$DARWIN_EXTSN + 8
1 libsystem_kernel.dylib 0x9334 __select + 8
2 CoreFoundation 0x1484b4 __CFSocketManager + 704
3 libsystem_pthread.dylib 0x17d0 _pthread_start + 136
4 libsystem_pthread.dylib 0x1480 thread_start + 8
Thread
0 libsystem_kernel.dylib 0x1510 __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x36cc _pthread_wqthread + 364
2 libsystem_pthread.dylib 0x1474 start_wqthread + 8
com.apple.CoreMotion.MotionThread
0 libsystem_kernel.dylib 0x1788 mach_msg2_trap + 8
1 libsystem_kernel.dylib 0x4e98 mach_msg2_internal + 80
2 libsystem_kernel.dylib 0x4db0 mach_msg_overwrite + 424
3 libsystem_kernel.dylib 0x4bfc mach_msg + 24
4 CoreFoundation 0x76804 __CFRunLoopServiceMachPort + 160
5 CoreFoundation 0x75eb0 __CFRunLoopRun + 1212
6 CoreFoundation 0xc8284 CFRunLoopRunSpecific + 588
7 CoreFoundation 0xdb824 CFRunLoopRun + 64
8 CoreMotion 0xf950 (缺少 UUID 6845c463baf9365fa47cf9617091a79a)
9 libsystem_pthread.dylib 0x17d0 _pthread_start + 136
10 libsystem_pthread.dylib 0x1480 thread_start + 8
Thread
0 libsystem_kernel.dylib 0x1510 __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x36cc _pthread_wqthread + 364
2 libsystem_pthread.dylib 0x1474 start_wqthread + 8
Thread
0 libsystem_kernel.dylib 0x1510 __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x36cc _pthread_wqthread + 364
2 libsystem_pthread.dylib 0x1474 start_wqthread + 8
Crashed: com.alamofire.networking.session.manager.processing
0 libobjc.A.dylib 0x2354 objc_release_x0 + 16
1 libobjc.A.dylib 0x2354 objc_release + 16
2 APP 0x16f64 -[AFHTTPResponseSerializer validateResponse:data:error:] + 118 (AFURLResponseSerialization.m:118)
3 APP 0x179d4 -[AFJSONResponseSerializer responseObjectForResponse:data:error:] + 239 (AFURLResponseSerialization.m:239)
4 APP 0x1a0c8 __72-[AFURLSessionManagerTaskDelegate URLSession:task:didCompleteWithError:]_block_invoke.35 + 222 (AFURLSessionManager.m:222)
5 libdispatch.dylib 0x2248 _dispatch_call_block_and_release + 32
6 libdispatch.dylib 0x3fa8 _dispatch_client_callout + 20
7 libdispatch.dylib 0x745c _dispatch_continuation_pop + 596
8 libdispatch.dylib 0x6a8c _dispatch_async_redirect_invoke + 580
9 libdispatch.dylib 0x15ec0 _dispatch_root_queue_drain + 392
10 libdispatch.dylib 0x166c4 _dispatch_worker_thread2 + 156
11 libsystem_pthread.dylib 0x3644 _pthread_wqthread + 228
12 libsystem_pthread.dylib 0x1474 start_wqthread + 8
Thread
0 libsystem_kernel.dylib 0x1510 __workq_kernreturn + 8
1 libsystem_pthread.dylib 0x36cc _pthread_wqthread + 364
2 libsystem_pthread.dylib 0x1474 start_wqthread + 8
com.google.GDTCORFlatFileStorage
0 libsystem_kernel.dylib 0x700c fstatat + 8
1 libsystem_kernel.dylib 0x700c fstatat64 + 8
2 libsystem_c.dylib 0x5cec _mkpath + 156
3 Foundation 0x15b6dc closure #1 in _FileManagerImpl.createDirectory(atPath:withIntermediateDirectories:attributes:) + 128
4 Foundation 0x15b654 partial apply for closure #1 in _FileManagerImpl.createDirectory(atPath:withIntermediateDirectories:attributes:) + 28
5 Foundation 0x15b558 specialized String.withFileSystemRepresentation<A>(_:) + 272
6 Foundation 0x15b320 specialized NSFileManager.withFileSystemRepresentation<A>(for:_:) + 248
7 Foundation 0x15b0dc @objc _NSFileManagerBridge.createDirectory(atPath:withIntermediateDirectories:attributes:) + 216
8 APP 0x103a48 GDTCORWriteDataToFile + 289 (GDTCORPlatform.m:289)
9 APP 0xfb71c __47-[GDTCORFlatFileStorage storeEvent:onComplete:]_block_invoke.42 + 171 (GDTCORFlatFileStorage.m:171)
10 libdispatch.dylib 0x2248 _dispatch_call_block_and_release + 32
11 libdispatch.dylib 0x3fa8 _dispatch_client_callout + 20
12 libdispatch.dylib 0xb5cc _dispatch_lane_serial_drain + 768
13 libdispatch.dylib 0xc124 _dispatch_lane_invoke + 380
14 libdispatch.dylib 0x1738c _dispatch_root_queue_drain_deferred_wlh + 288
15 libdispatch.dylib 0x16bd8 _dispatch_workloop_worker_thread + 540
16 libsystem_pthread.dylib 0x3680 _pthread_wqthread + 288
17 libsystem_pthread.dylib 0x1474 start_wqthread + 8
If using Swift Package Manager, the project's Package.resolved
Expand Package.resolved
snippet
Replace this line with the contents of your Package.resolved.
If using CocoaPods, the project's Podfile.lock
PODS:
- AFNetworking (4.0.1):
- AFNetworking/NSURLSession (= 4.0.1)
- AFNetworking/Reachability (= 4.0.1)
- AFNetworking/Security (= 4.0.1)
- AFNetworking/Serialization (= 4.0.1)
- AFNetworking/UIKit (= 4.0.1)
- AFNetworking/NSURLSession (4.0.1):
- AFNetworking/Reachability
- AFNetworking/Security
- AFNetworking/Serialization
- AFNetworking/Reachability (4.0.1)
- AFNetworking/Security (4.0.1)
- AFNetworking/Serialization (4.0.1)
- AFNetworking/UIKit (4.0.1):
- AFNetworking/NSURLSession
- Bifrost (1.0.0)
- Firebase/CoreOnly (10.29.0):
- FirebaseCore (= 10.29.0)
- Firebase/Crashlytics (10.29.0):
- Firebase/CoreOnly
- FirebaseCrashlytics (~> 10.29.0)
- FirebaseABTesting (10.29.0):
- FirebaseCore (~> 10.0)
- FirebaseCore (10.29.0):
- FirebaseCoreInternal (~> 10.0)
- GoogleUtilities/Environment (~> 7.12)
- GoogleUtilities/Logger (~> 7.12)
- FirebaseCoreExtension (10.29.0):
- FirebaseCore (~> 10.0)
- FirebaseCoreInternal (10.29.0):
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- FirebaseCrashlytics (10.29.0):
- FirebaseCore (~> 10.5)
- FirebaseInstallations (~> 10.0)
- FirebaseRemoteConfigInterop (~> 10.23)
- FirebaseSessions (~> 10.5)
- GoogleDataTransport (~> 9.2)
- GoogleUtilities/Environment (~> 7.8)
- nanopb (< 2.30911.0, >= 2.30908.0)
- PromisesObjC (~> 2.1)
- FirebaseInstallations (10.29.0):
- FirebaseCore (~> 10.0)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/UserDefaults (~> 7.8)
- PromisesObjC (~> 2.1)
- FirebaseMessaging (10.29.0):
- FirebaseCore (~> 10.0)
- FirebaseInstallations (~> 10.0)
- GoogleDataTransport (~> 9.3)
- GoogleUtilities/AppDelegateSwizzler (~> 7.8)
- GoogleUtilities/Environment (~> 7.8)
- GoogleUtilities/Reachability (~> 7.8)
- GoogleUtilities/UserDefaults (~> 7.8)
- nanopb (< 2.30911.0, >= 2.30908.0)
- FirebasePerformance (10.29.0):
- FirebaseCore (~> 10.5)
- FirebaseInstallations (~> 10.0)
- FirebaseRemoteConfig (~> 10.0)
- FirebaseSessions (~> 10.5)
- GoogleDataTransport (~> 9.2)
- GoogleUtilities/Environment (~> 7.13)
- GoogleUtilities/ISASwizzler (~> 7.13)
- GoogleUtilities/MethodSwizzler (~> 7.13)
- GoogleUtilities/UserDefaults (~> 7.13)
- nanopb (< 2.30911.0, >= 2.30908.0)
- FirebaseRemoteConfig (10.29.0):
- FirebaseABTesting (~> 10.0)
- FirebaseCore (~> 10.0)
- FirebaseInstallations (~> 10.0)
- FirebaseRemoteConfigInterop (~> 10.23)
- FirebaseSharedSwift (~> 10.0)
- GoogleUtilities/Environment (~> 7.8)
- "GoogleUtilities/NSData+zlib (~> 7.8)"
- FirebaseRemoteConfigInterop (10.29.0)
- FirebaseSessions (10.29.0):
- FirebaseCore (~> 10.5)
- FirebaseCoreExtension (~> 10.0)
- FirebaseInstallations (~> 10.0)
- GoogleDataTransport (~> 9.2)
- GoogleUtilities/Environment (~> 7.13)
- GoogleUtilities/UserDefaults (~> 7.13)
- nanopb (< 2.30911.0, >= 2.30908.0)
- PromisesSwift (~> 2.1)
- FirebaseSharedSwift (10.29.0)
- FMDB (2.7.12):
- FMDB/standard (= 2.7.12)
- FMDB/Core (2.7.12)
- FMDB/standard (2.7.12):
- FMDB/Core
- GoogleDataTransport (9.4.1):
- GoogleUtilities/Environment (~> 7.7)
- nanopb (< 2.30911.0, >= 2.30908.0)
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/AppDelegateSwizzler (7.13.3):
- GoogleUtilities/Environment
- GoogleUtilities/Logger
- GoogleUtilities/Network
- GoogleUtilities/Privacy
- GoogleUtilities/Environment (7.13.3):
- GoogleUtilities/Privacy
- PromisesObjC (< 3.0, >= 1.2)
- GoogleUtilities/ISASwizzler (7.13.3):
- GoogleUtilities/Privacy
- GoogleUtilities/Logger (7.13.3):
- GoogleUtilities/Environment
- GoogleUtilities/Privacy
- GoogleUtilities/MethodSwizzler (7.13.3):
- GoogleUtilities/Logger
- GoogleUtilities/Privacy
- GoogleUtilities/Network (7.13.3):
- GoogleUtilities/Logger
- "GoogleUtilities/NSData+zlib"
- GoogleUtilities/Privacy
- GoogleUtilities/Reachability
- "GoogleUtilities/NSData+zlib (7.13.3)":
- GoogleUtilities/Privacy
- GoogleUtilities/Privacy (7.13.3)
- GoogleUtilities/Reachability (7.13.3):
- GoogleUtilities/Logger
- GoogleUtilities/Privacy
- GoogleUtilities/UserDefaults (7.13.3):
- GoogleUtilities/Logger
- GoogleUtilities/Privacy
- HMSegmentedControl (1.5.6)
- IQKeyboardManager (5.0.8)
- lottie-ios (2.5.3)
- Masonry (1.1.0)
- MBProgressHUD (1.1.0)
- MJRefresh (3.1.15.7)
- nanopb (2.30910.0):
- nanopb/decode (= 2.30910.0)
- nanopb/encode (= 2.30910.0)
- nanopb/decode (2.30910.0)
- nanopb/encode (2.30910.0)
- ObjectMapper (4.2.0)
- PromisesObjC (2.4.0)
- PromisesSwift (2.4.0):
- PromisesObjC (= 2.4.0)
- SDWebImage (5.10.0):
- SDWebImage/Core (= 5.10.0)
- SDWebImage/Core (5.10.0)
- SnapKit (5.7.1)
- SocketRocket (0.7.1)
- SSZipArchive (1.8.1)
- SVProgressHUD (2.2.5)
- SwiftyJSON (4.3.0)
- TOCropViewController (2.0.12)
- Yoga (1.14.0)
- YogaKit (1.18.1):
- Yoga (~> 1.14)
- YYModel (1.0.4)
- YYText (1.0.7)
DEPENDENCIES:
- AFNetworking (= 4.0.1)
- Bifrost
- Firebase/Crashlytics
- FirebaseCore
- FirebaseMessaging
- FirebasePerformance
- FMDB (~> 2.7.2)
- HMSegmentedControl (~> 1.5.4)
- IQKeyboardManager (~> 5.0.7)
- lottie-ios (~> 2.5.0)
- Masonry (~> 1.1.0)
- MBProgressHUD (~> 1.1.0)
- MJRefresh (~> 3.1.15.3)
- ObjectMapper
- SDWebImage (= 5.10.0)
- SnapKit
- SocketRocket
- SSZipArchive (~> 1.8.1)
- SVProgressHUD (~> 2.2.5)
- SwiftyJSON (~> 4.0)
- TOCropViewController (~> 2.0.12)
- Yoga (from
Modules/Home/Home/Common
) - YogaKit (from
Modules/Home/Home/Common
) - YYModel (~> 1.0.4)
- YYText (~> 1.0.7)
SPEC REPOS:
trunk:
- AFNetworking
- Bifrost
- Firebase
- FirebaseABTesting
- FirebaseCore
- FirebaseCoreExtension
- FirebaseCoreInternal
- FirebaseCrashlytics
- FirebaseInstallations
- FirebaseMessaging
- FirebasePerformance
- FirebaseRemoteConfig
- FirebaseRemoteConfigInterop
- FirebaseSessions
- FirebaseSharedSwift
- FMDB
- GoogleDataTransport
- GoogleUtilities
- HMSegmentedControl
- IQKeyboardManager
- lottie-ios
- Masonry
- MBProgressHUD
- MJRefresh
- nanopb
- ObjectMapper
- PromisesObjC
- PromisesSwift
- SDWebImage
- SnapKit
- SocketRocket
- SSZipArchive
- SVProgressHUD
- SwiftyJSON
- TOCropViewController
- YYModel
- YYText
EXTERNAL SOURCES:
Yoga:
:path: Modules/Home/Home/Common
YogaKit:
:path: Modules/Home/Home/Common
SPEC CHECKSUMS:
AFNetworking: 3bd23d814e976cd148d7d44c3ab78017b744cd58
Bifrost: 2eb95b8054a8fe34845dd6cdd9b4af492f58f203
Firebase: cec914dab6fd7b1bd8ab56ea07ce4e03dd251c2d
FirebaseABTesting: d87f56707159bae64e269757a6e963d490f2eebe
FirebaseCore: 30e9c1cbe3d38f5f5e75f48bfcea87d7c358ec16
FirebaseCoreExtension: 705ca5b14bf71d2564a0ddc677df1fc86ffa600f
FirebaseCoreInternal: df84dd300b561c27d5571684f389bf60b0a5c934
FirebaseCrashlytics: 34647b41e18de773717fdd348a22206f2f9bc774
FirebaseInstallations: 913cf60d0400ebd5d6b63a28b290372ab44590dd
FirebaseMessaging: 7b5d8033e183ab59eb5b852a53201559e976d366
FirebasePerformance: d0ac4aa90f8c1aedeb8d0329a56e2d77d8d9e004
FirebaseRemoteConfig: 48ef3f243742a8d72422ccfc9f986e19d7de53fd
FirebaseRemoteConfigInterop: 6efda51fb5e2f15b16585197e26eaa09574e8a4d
FirebaseSessions: dbd14adac65ce996228652c1fc3a3f576bdf3ecc
FirebaseSharedSwift: 20530f495084b8d840f78a100d8c5ee613375f6e
FMDB: 728731dd336af3936ce00f91d9d8495f5718a0e6
GoogleDataTransport: 6c09b596d841063d76d4288cc2d2f42cc36e1e2a
GoogleUtilities: ea963c370a38a8069cc5f7ba4ca849a60b6d7d15
HMSegmentedControl: 34c1f54d822d8308e7b24f5d901ec674dfa31352
IQKeyboardManager: 266cb7b1d11f94a3e71229d77f960f9a1b538e5b
lottie-ios: a50d5c0160425cd4b01b852bb9578963e6d92d31
Masonry: 678fab65091a9290e40e2832a55e7ab731aad201
MBProgressHUD: e7baa36a220447d8aeb12769bf0585582f3866d9
MJRefresh: 697f8ec75ebdbe9207767bb682cf0f51b0d8a41f
nanopb: 438bc412db1928dac798aa6fd75726007be04262
ObjectMapper: 1eb41f610210777375fa806bf161dc39fb832b81
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
PromisesSwift: 9d77319bbe72ebf6d872900551f7eeba9bce2851
SDWebImage: 9169792e9eec3e45bba2a0c02f74bf8bd922d1ee
SnapKit: d612e99e678a2d3b95bf60b0705ed0a35c03484a
SocketRocket: d4aabe649be1e368d1318fdf28a022d714d65748
SSZipArchive: 04547dfa448be5ed7ecbaf7eaf8a6e9eb9b42997
SVProgressHUD: 1428aafac632c1f86f62aa4243ec12008d7a51d6
SwiftyJSON: 6faa0040f8b59dead0ee07436cbf76b73c08fd08
TOCropViewController: e6e31b38d785a901e5651a1e7fff71bcda6c5214
Yoga: f35650c3fa4d06b7b6e70b1e9f30df69478f90cb
YogaKit: 975228555fc48bc59c08c36cddcfef24f8aa1cc7
YYModel: 2a7fdd96aaa4b86a824e26d0c517de8928c04b30
YYText: 5c461d709e24d55a182d1441c41dc639a18a4849
PODFILE CHECKSUM: 2aeeb297818c76b0b6cb6b9137fc493a25e8b2fd
COCOAPODS: 1.16.2