title: Setting data in background thread and getting bad_access error
body: <p>My goal is to initialize a large amount of data on a different (non-main) thread, and then refresh a <code>UIProgressView</code> on the main thread corresponding to the large data load's progress. To do this, I use <code>performSelectorInBackground</code> to load the data, and update the progress throughout the way using <code>performSelectorOnMainThread</code>.</p>
  
  <p>I am currently getting a <code>EXE_BAD_ACCESS</code> error from one of the dictionaries that I am initializing, specifically the line where I am setting <code>self.someDictionary = @{...}</code>. <code>self.someDictionary</code> takes on <code>strong</code> and <code>nonatomic</code> properties, and is initialized on the non-main thread.</p>
  
  <p>As a total newbie to multithreading, I am beginning to see that I shouldn't be setting a strong and <code>nonatomic</code> property (however, changing it to <code>atomic</code> still caused the crash). What else am I doing incorrectly to cause the <code>EXE_BAD_ACCESS</code> error, and how do I set a large amount of data to an NSDictionary on a non-main thread and still be able to update the progress on the main thread?</p>
  
  <p>Thanks!</p>
  
  <p>Edit 1:</p>
  
  <p>Code:</p>
  
  <pre><code>//In viewWillAppear, from the main thread
  [self performSelectorInBackground:@selector(populateDictionaries) withObject:nil];
  
  //In populateDictionaries method
  Dictionary *someDictionary = [[Dictionary alloc] init];
  
  //the methods inside the Dictionary class
  - (id) init{
      self = [super init];
      if (self){
          [self makeDictionaries];
      }
  
      return self;
  }
  - (void)makeDictionaries{
  
      self.insiderDictionary = @{ ...} //this line is causing the crash
  
  }
  </code></pre>