title: Thread 1: EXC_BAD_ACCESS (code =2, address=0*879fc0)
body: <p>I've a UITableViewController (CoffeeBeansViewController) that looks up the values from a sqlite table and display the contents in a table. </p>
  
  <pre><code>- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
  {
      static NSString *CellIdentifier = @"RegionCell";
      UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
  
      // Configure the cell...
      if (cell == nil) {
          cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier];
  }
      int rowCount = indexPath.row;
      CoffeeBeans *coffeeBeans = [self.theCoffees objectAtIndex:rowCount];
      cell.textLabel.text = coffeeBeans.region;
      cell.detailTextLabel.text = coffeeBeans.variety;
  
      return cell;  
  }
  </code></pre>
  
  <p>Upon exiting the function, the program crashes with the error:
  Thread 1: EXC_BAD_ACCESS (code =2, address=0*879fc0).</p>
  
  <pre><code>libobjc.A.dylib`objc_release:
  0xf90dd0:  pushl  %ebp
  0xf90dd1:  movl   %esp, %ebp
  0xf90dd3:  subl   $8, %esp
  0xf90dd6:  calll  0xf90ddb                  ; objc_release + 11
  0xf90ddb:  popl   %ecx
  0xf90ddc:  movl   8(%ebp), %eax
  0xf90ddf:  testl  %eax, %eax
  0xf90de1:  je     0xf90e00                  ; objc_release + 48
  0xf90de3:  movl   (%eax), %edx
  0xf90de5:  movl   16(%edx), %edx
  0xf90de8:  testb  $4, 2(%edx)               &lt;error message is here&gt;
  0xf90dec:  je     0xf90e05                  ; objc_release + 53
  0xf90dee:  movl   775957(%ecx), %ecx
  0xf90df4:  movl   %ecx, 4(%esp)
  0xf90df8:  movl   %eax, (%esp)
  0xf90dfb:  calll  0xf9008c                  ; objc_msgSend
  0xf90e00:  addl   $8, %esp
  0xf90e03:  popl   %ebp
  0xf90e04:  ret    
  0xf90e05:  addl   $8, %esp
  0xf90e08:  popl   %ebp
  0xf90e09:  jmp    0
  </code></pre>
  
  <p>In the l-h column, it highlights '0 objc_release' under Thread 1.</p>
  
  <p>Can anyone help me with this error? Thanks.</p>