gpt4 book ai didi

ios 应用程序在启动时发生奇怪的崩溃

转载 作者:可可西里 更新时间:2023-11-01 04:41:54 29 4
gpt4 key购买 nike

我的项目名为 OBI,从 Xcode 启动时运行良好,但当我创建 .ipa 文件时,它会崩溃并提供日志。在项目中没有名称为:MutexDelayedPointerDeletionManagerMemoryManager 的类,因此我无法理解此异常的来源。

Thread 0 Crashed:
0 libsystem_pthread.dylib 0x396b7046 _pthread_mutex_check_init + 14
1 libsystem_pthread.dylib 0x396b6e32 _pthread_mutex_lock + 22
2 OBI 0x02a74f20 Mutex::Lock() (Mutex.cpp:152)
3 OBI 0x02838930 DelayedPointerDeletionManager::AddPointerToMainThreadDealloc(void*, MemLabelId) (Mutex.h:32)
4 OBI 0x028384a4 MemoryManager::Deallocate(void*, MemLabelId) (MemoryManager.cpp:1082)
5 OBI 0x028384e4 operator delete[](void*) (MemoryManager.cpp:114)
6 OBI 0x01d28010 std::locale::locale<boost::filesystem::detail::utf8_codecvt_facet>(std::locale const&, boost::filesystem::detail::utf8_codecvt_facet*) (locale_classes.h:581)
7 OBI 0x01d281c4 ___lldb_unnamed_function148423$$OBI + 232
8 dyld 0x2be5b59e ImageLoaderMachO::doModInitFunctions(ImageLoader::LinkContext const&) + 174
9 dyld 0x2be5b6ac ImageLoaderMachO::doInitialization(ImageLoader::LinkContext const&) + 16
10 dyld 0x2be58d34 ImageLoader::recursiveInitialization(ImageLoader::LinkContext const&, unsigned int, ImageLoader::InitializerTimingList&) + 356
11 dyld 0x2be58b88 ImageLoader::runInitializers(ImageLoader::LinkContext const&, ImageLoader::InitializerTimingList&) + 36
12 dyld 0x2be4fd38 dyld::initializeMainExecutable() + 164
13 dyld 0x2be52ab4 dyld::_main(macho_header const*, unsigned long, int, char const**, char const**, char const**, unsigned long*) + 1748
14 dyld 0x2be4f22a dyldbootstrap::start(macho_header const*, int, char const**, long, macho_header const*, unsigned long*) + 346
15 dyld 0x2be4f064 _dyld_start + 60

编辑,来自控制台的几行。

Oct 16 14:43:18 Sergiys-iPad kernel[0] <Debug>: launchd[9526] Container: /private/var/mobile/Applications/AA46736B-6348-42BA-A8F0-DD63DC535AF6 (sandbox)
Oct 16 14:43:19 Sergiys-iPad ReportCrash[9527] <Notice>: ReportCrash acting against PID 9526
Oct 16 14:43:19 Sergiys-iPad ReportCrash[9527] <Notice>: Formulating crash report for process OBI[9526]
Oct 16 14:43:19 Sergiys-iPad com.apple.launchd[1] (UIKitApplication:com.mycompany.OBIQA[0x14dc][9526]) <Warning>: (UIKitApplication:com.mycompany.OBIQA[0x14dc]) Job appears to have crashed: Segmentation fault: 11
Oct 16 14:43:19 Sergiys-iPad com.apple.launchd[1] (UIKitApplication:com.mycompany.OBIQA[0x14dc]) <Notice>: (UIKitApplication:com.mycompany.OBIQA[0x14dc]) Throttling respawn: Will start in 2147483647 seconds
Oct 16 14:43:19 Sergiys-iPad backboardd[28] <Warning>: Application 'UIKitApplication:com.mycompany.OBIQA[0x14dc]' exited abnormally with signal 11: Segmentation fault: 11
Oct 16 14:43:19 Sergiys-iPad SpringBoard[33] <Warning>: Application 'com.mycompany.OBIQA' has failed to launch too many times. Not relaunching.
Oct 16 14:43:19 Sergiys-iPad ReportCrash[9527] <Notice>: Saved crashreport to /var/mobile/Library/Logs/CrashReporter/OBI_2013-10-16-144319_Sergiys-iPad.plist using uid: 0 gid: 0, synthetic_euid: 501 egid: 0

如果有任何帮助或挖掘方向,我将非常高兴

编辑最后我找到了导致这个异常的原因。build设置中的 symbol striping 选项,在我将其从 all symbols 更改为 debug symbols 后,一切都变得很好。

最佳答案

当 iOS 将您的类加载到内存中时,这会在动态加载器中崩溃。此过程的一部分是在任何实现该方法的类上调用 +load。

一种可能是您在 +load 中做了太多工作,并因“未能及时启动”而被杀死。提供完整的崩溃日志将显示是否属于这种情况。

关于ios 应用程序在启动时发生奇怪的崩溃,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19402289/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com