iOS端sigsegv(segv_访问)上的小概率崩溃事件

iOS端sigsegv(segv_访问)上的小概率崩溃事件,ios,crash,Ios,Crash,我的问题是如何定位崩溃的特定函数指令,就像系统函数有崩溃的汇编指令堆栈一样;或者,为了分析可能的原因,我个人认为可能是*错误指针在另一个线程中被释放了,这就是野生指针问题,但是如何验证它呢 其中projectName表示项目名称,表示它是项目的内部功能,而不是系统功能 崩溃堆栈信息如下所示: 崩溃线程###0线程## 西格塞格夫 塞格沃·阿克尔 从堆栈上看,这似乎是启动时造成的崩溃 0 projectName -[FlexTemplateManager dataForPath

我的问题是如何定位崩溃的特定函数指令,就像系统函数有崩溃的汇编指令堆栈一样;或者,为了分析可能的原因,我个人认为可能是*错误指针在另一个线程中被释放了,这就是野生指针问题,但是如何验证它呢

其中projectName表示项目名称,表示它是项目的内部功能,而不是系统功能

崩溃堆栈信息如下所示:

崩溃线程###0线程## 西格塞格夫 塞格沃·阿克尔

从堆栈上看,这似乎是启动时造成的崩溃

        0 projectName   -[FlexTemplateManager dataForPath:error:] + 132
        1 projectName   -[FlexTemplateManager dataForPath:error:] + 124
        2 projectName   -[FlexTemplateManager jsonForPath:error:] + 28
        3 projectName   -[FlexTemplateManager dimensionConfig] + 140
        ...
        31 UIKitCore    -[UIScene _emitSceneSettingsUpdateResponseForCompletion:afterSceneUpdateWork:] + 248
        32 UIKitCore    -[UIScene scene:didUpdateWithDiff:transitionContext:completion:] + 220
        33 UIKitCore    -[UIApplication workspace:didCreateScene:withTransitionContext:completion:] + 548
        34 UIKitCore    -[UIApplicationSceneClientAgent scene:didInitializeWithEvent:completion:] + 360
        35 FrontBoardServices   -[FBSSceneImpl _callOutQueue_agent_didCreateWithTransitionContext:completion:] + 436
        36 FrontBoardServices   ___86-[FBSWorkspaceScenesClient sceneID:createWithParameters:transitionContext:completion:]_block_invoke.154 + 100
        37 FrontBoardServices   -[FBSWorkspace _calloutQueue_executeCalloutFromSource:withBlock:] + 232
        38 FrontBoardServices   ___86-[FBSWorkspaceScenesClient sceneID:createWithParameters:transitionContext:completion:]_block_invoke + 312
        ...
        42 FrontBoardServices   -[FBSSerialQueue _queue_performNextIfPossible] + 404
        43 FrontBoardServices   -[FBSSerialQueue _performNextFromRunLoopSource] + 28
        44 CoreFoundation   ___CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 24
        45 CoreFoundation   ___CFRunLoopDoSource0 + 80
        46 CoreFoundation   ___CFRunLoopDoSources0 + 180
        47 CoreFoundation   ___CFRunLoopRun + 1080
        48 CoreFoundation   CFRunLoopRunSpecific + 464
        49 GraphicsServices GSEventRunModal + 104
        50 UIKitCore    UIApplicationMain + 1936
        51 projectName  main (main.m:21)
        52 libdyld.dylib    _start + 4
通过计算偏移量“*error=[NSError errorWithCode:-10 message:@”来指定崩溃线文件路径为空“];”

    - (NSData *)dataForPath:(NSString *)filePath error:(NSError *__autoreleasing *)error {
            if (filePath == nil) {
                if (error) {
                    *error = [NSError errorWithCode:-10 message:@"文件路径为空"];
                }
                return nil;
            }
            ...
    }

    + (instancetype)errorWithCode:(NSInteger)code message:(NSString *)message {
        return [NSError errorWithDomain:NSLocalizedDescriptionKey code:code message:message];
    }