Google reveals no posts at all for this error message. I\'m getting it in iOS 5 trying to update a UITableView. While the exact code is a bit tortured, this is what I\'m doi
Leaving this here as well as a separate possible cause.
If you are trying to delete rows in the moveRowAtIndexPath:
method you will get the same crash. You have to wait until it finishes to do that.
Looks like your code is trying to work with a section of your table that does not exist.
Since NSArrays are zero-indexed, the index value of count
will be outside the bounds of the array. You should subtract one from the count when using indexSetWithIndex:
here:
[table insertSections: [NSIndexSet indexSetWithIndex: [sections count]-1]
withRowAnimation: UITableViewRowAnimationNone];
Posting as answer in case it happens to somebody else as well.
I found the issue looking at jonkroll's answer, but in my case this happened because I was calling the same method twice and that method removed a row from the table view.