title: App crash on startup with only update not fresh install
body: <p>I have a strange issue with my latest version on App store. Some users report that the app crash on startup after upgrading the app and it only happens with iOS6. However, the crash will not happen if the user delete the app and have a fresh install.</p>
  
  <p>I check the crash log on the phone and see this error.</p>
  
  <pre><code>OS Version:      iOS 6.0 (10A403)
  
  Exception Type:  EXC_BAD_ACCESS (SIGBUS)
  Exception Codes: EXC_ARM_DA_ALIGN at 0x2fe6f785
  Crashed Thread:  0
  
  Thread 0 name:  Dispatch queue: com.apple.main-thread
  Thread 0 Crashed:
  0   My App                          0x00074ace +[aClass sharedNormalImages] (aClass.m:34)
  1   dyld                            0x2fe79628 ImageLoaderMachO::doInitialization(ImageLoader::LinkContext const&amp;) + 16
  2   dyld                            0x2fe76a3a ImageLoader::recursiveInitialization(ImageLoader::LinkContext const&amp;, unsigned int, ImageLoader::InitializerTimingList&amp;) + 382
  3   dyld                            0x2fe76874 ImageLoader::runInitializers(ImageLoader::LinkContext const&amp;, ImageLoader::InitializerTimingList&amp;) + 36
  4   dyld                            0x2fe6dd04 dyld::initializeMainExecutable() + 172
  5   dyld                            0x2fe7085c dyld::_main(macho_header const*, unsigned long, int, char const**, char const**, char const**, unsigned long*) + 1804
  6   dyld                            0x2fe6d32c dyldbootstrap::start(macho_header const*, int, char const**, long, macho_header const*, unsigned long*) + 604
  7   dyld                            0x2fe6d064 _dyld_start + 60
  </code></pre>
  
  <p>The sharedNormalImages function has not been changed at all from the recent version and it is just a function that return an array like this.</p>
  
  <pre><code>static NSArray *normalImages = nil;
  + (NSArray *)sharedNormalImages
  {
       if (normalImages == nil) {
               normalImages = @[@"xx.png", @"xy.png", @"yx.png", @"yy.png"];
       }
  
       return normalImages;
  }
  </code></pre>
  
  <p>I really have no idea what happen. I tried to install with the old version and then replace with the new version with Xcode. The problem also does not happen. So I cannot replicate it with my environment at all. That is so strange.</p>
  
  <p><strong>Edit</strong></p>
  
  <p>Not sure how it could be related but I see this error message on the device console. </p>
  
  <pre><code>Oct 19 12:36:16 iPhone My App[210] &lt;Error&gt;: objc[210]: Class  is implemented in both /var/mobile/Applications/A5EC61E7-7DBA-4FA5-A5FE-6D49EAFAD6EB/My App.app/My App and /var/mobile/Applications/A5EC61E7-7DBA-4FA5-A5FE-6D49EAFAD6EB/My App.app/My App. One of the two will be used. Which one is undefined.
  Oct 19 12:36:16 iPhone kernel[0] &lt;Debug&gt;: launchd[210] Builtin profile: container (sandbox)
  Oct 19 12:36:16 iPhone kernel[0] &lt;Debug&gt;: launchd[210] Container: /private/var/mobile/Applications/A5EC61E7-7DBA-4FA5-A5FE-6D49EAFAD6EB (sandbox)
  Oct 19 12:36:16 iPhone ReportCrash[211] &lt;Notice&gt;: Formulating crash report for process My App[210]
  Oct 19 12:36:16 iPhone com.apple.launchd[1] (UIKitApplication:com.acompany.myapp[0x813f][210]) &lt;Warning&gt;: (UIKitApplication:com.acompany.myapp[0x813f]) Job appears to have crashed: Bus error: 10
  Oct 19 12:36:16 iPhone com.apple.launchd[1] (UIKitApplication:com.acompany.myapp[0x813f]) &lt;Notice&gt;: (UIKitApplication:com.acompany.myapp[0x813f]) Throttling respawn: Will start in 2147483647 seconds
  Oct 19 12:36:16 iPhone backboardd[52] &lt;Warning&gt;: Application 'UIKitApplication:com.acompany.myapp[0x813f]' exited abnormally with signal 10: Bus error: 10
  Oct 19 12:36:16 iPhone ReportCrash[211] &lt;Error&gt;: libMobileGestalt copySystemVersionDictionaryValue: Could not lookup ReleaseType from system version dictionary
  Oct 19 12:36:16 iPhone ReportCrash[211] &lt;Notice&gt;: Saved crashreport to /var/mobile/Library/Logs/CrashReporter/My App_2012-10-19-123616_iPhone.plist using uid: 0 gid: 0, synthetic_euid: 501 egid: 0
  </code></pre>
  
  <p>FYI, I update the app icon to be "prerendered" on the latest update but I don't think that could make the crash.</p>