instantiateNibWithOwner: fails due to "mutated while enumerated"
instantiateNibWithOwner: fails due to "mutated while enumerated"
- Subject: instantiateNibWithOwner: fails due to "mutated while enumerated"
- From: Philip White <email@hidden>
- Date: Tue, 05 May 2009 14:38:19 -0600
Hello,
I changed the target on my program from 10.4 to 10.5, built it
fine but now the following line of code fails:
[[self nib] instantiateNibWithOwner:self
topLevelObjects:&topLevelObjects];
where [self nib] is simply
-(NSNib*)nib
{
static NSNib *nib=nil;
if (nib == nil)
nib = [[NSNib alloc] initWithNibNamed: @"DummyName" bundle: nil];
return nib;
}
The call to initWithNibNamed: works fine and I get an NSNib instance
back but instantiateNibWithOwner: fails and logs:
"*** Collection <NSCFArray: 0x17bab0> was mutated while being
enumerated."
That array is not one that I have allocated, nor am I enumerating
anything when I call that method. Just to be sure I tried invoking
that bit of code first thing in my program and it still fails. I also
tried passing NULL instead of &topLevelObjects but it made no
difference.
Again, no problems under 10.4.
I'm running this on a Powerbook G4 running 10.5.6. and XCode 3.1.2
Thanks,
Philip
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden