Hi,<div>I have more info about the crash I reported yesterday:</div><div><div><br></div><div><div><unknown program name>(21398)/ KDevelop::allocateGlobalItemRepositoryRegistry: testing "/Users/ccpasteur/.kdevduchain/0"</div>
<div><unknown program name>(21398)/ KDevelop::allocateGlobalItemRepositoryRegistry: picked duchain directory "/Users/ccpasteur/.kdevduchain/0"</div><div><unknown program name>(21398)/ KDevelop::ItemRepositoryRegistry::open: "/Users/ccpasteur/.kdevduchain/0/version_42" not found, seems to be an old version </div>
<div><unknown program name>(21398)/ KDevelop::ItemRepositoryRegistry::open: "The data-repository at /Users/ccpasteur/.kdevduchain/0 has to be cleared. Either the disk format has changed, or KDevelop crashed while writing the repository" </div>
<div><br></div><div>Program received signal EXC_BAD_ACCESS, Could not access memory.</div><div>Reason: KERN_PROTECTION_FAILURE at address: 0x00000010</div><div>0x0247864f in QMutex::lock ()</div></div><div><br></div><div>
<br></div><div>#0 0x0247864f in QMutex::lock ()</div><div>warning: .o file "/Users/ccpasteur/dev/kdevplatform/build/language/CMakeFiles/kdevplatformlanguage.dir/editor/modificationrevisionset.o" more recent than executable timestamp</div>
<div>#1 0x02cb10e6 in QMutexLocker::relock (this=0xbfffdde8) at qmutex.h:116</div><div>#2 0x02cb1155 in QMutexLocker::QMutexLocker (this=0xbfffdde8, m=0x10) at qmutex.h:98</div><div>warning: .o file "/Users/ccpasteur/dev/kdevplatform/build/language/CMakeFiles/kdevplatformlanguage.dir/duchain/indexedstring.o" more recent than executable timestamp</div>
<div>#3 0x02d7fd5c in KDevelop::RepositoryManager<KDevelop::ItemRepository<Repositories::StringData, Repositories::StringRepositoryItemRequest, KDevelop::ReferenceCounting, true, 0u, 524288u>, true, true>::createRepository (this=0x2e9df64) at repositories/itemrepository.h:189</div>
<div>#4 0x02d7fe6f in KDevelop::RepositoryManager<KDevelop::ItemRepository<Repositories::StringData, Repositories::StringRepositoryItemRequest, KDevelop::ReferenceCounting, true, 0u, 524288u>, true, true>::operator-> (this=0x2e9df64) at repositories/itemrepository.h:180</div>
<div>#5 0x02d7f3be in KDevelop::IndexedString::IndexedString (this=0xbfffdea4, string=@0xbfffdea8) at /Users/ccpasteur/dev/kdevplatform/language/duchain/indexedstring.cpp:68</div><div>warning: .o file "/Users/ccpasteur/dev/kdevplatform/build/language/CMakeFiles/kdevplatformlanguage.dir/duchain/identifier.o" more recent than executable timestamp</div>
<div>#6 0x02d49e20 in KDevelop::Identifier::Identifier (this=0x2e9de34, id=@0xbfffdefc, start=0, takenRange=0x0) at /Users/ccpasteur/dev/kdevplatform/language/duchain/identifier.cpp:299</div><div>#7 0x02e04559 in __static_initialization_and_destruction_0 ()</div>
<div>#8 0x02e045d4 in global constructors keyed to _ZN8KDevelop20DUContextDynamicData24m_localDeclarationsMutexE ()</div><div>#9 0x8fe12f36 in __dyld__ZN16ImageLoaderMachO18doModInitFunctionsERKN11ImageLoader11LinkContextE ()</div>
<div>#10 0x8fe0e7e3 in __dyld__ZN11ImageLoader23recursiveInitializationERKNS_11LinkContextEj ()</div><div>#11 0x8fe0e775 in __dyld__ZN11ImageLoader23recursiveInitializationERKNS_11LinkContextEj ()</div><div>#12 0x8fe0e775 in __dyld__ZN11ImageLoader23recursiveInitializationERKNS_11LinkContextEj ()</div>
<div>#13 0x8fe0e8c9 in __dyld__ZN11ImageLoader15runInitializersERKNS_11LinkContextE ()</div><div>#14 0x8fe04102 in __dyld__ZN4dyld24initializeMainExecutableEv ()</div><div>#15 0x8fe07bcf in __dyld__ZN4dyld5_mainEPK11mach_headermiPPKcS5_S5_ ()</div>
<div>#16 0x8fe01872 in __dyld__ZN13dyldbootstrap5startEPK11mach_headeriPPKcl ()</div><div>#17 0x8fe01037 in __dyld__dyld_start ()</div><div><br></div><div># gcc --v</div><div><div>i686-apple-darwin9-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5564)</div>
</div><div><br></div><div>It seems that the ItemRepositoryRegistry& m_registry is unitialized at the point the createRepository method is called. Maybe it's related to the order of initialization of static objects as I've seen there was a comment about it in the file that could explain.</div>
<div><br></div><div>Best regards</div></div>