Re: String retrieval error... Please help
Re: String retrieval error... Please help
- Subject: Re: String retrieval error... Please help
- From: Lloyd Dupont <email@hidden>
- Date: Mon, 14 Apr 2003 13:22:17 +1000
what about :
[pathToIcon release];
pathToIcon = [[volume volumeIconPath:pathToIcon] retain];
?
On Monday, April 14, 2003, at 01:08 PM, Brian Ganninger wrote:
Greetings all,
I've been banging my head against the wall for hours and I can't
figure out
why this is causing me such problems so I'm hoping all the talented
programmers of this list can tell me how I'm stupid.
while((object = [enumerator nextObject]) && (object2 = [enumerator2
nextObject]))
{
volume = [volumeMatrix objectAtIndex:updateLoop];
if([volume useState] == YES)
{
percentUsed = object2;
[self saveBackupIcon:object];
pathToIcon = [volume volumeIconPath];
[self setDriveIcon:object usingIcon:pathToIcon];
}
updateLoop++;
}
Object is an array with string paths, object2 is an array with
strings, all
variables other than object, object2, & volume (and updateLoop) are
global.
The volumeMatrix is a mutable array containing objects. Each is a
'volume',
which is just an instance of one of my custom classes.
The volumeIconPath method is just a simple return method to return the
volumeIconPath string from inside the volume.
PathToIcon becomes invalid after this command which then crashes my
app.
Any help is greatly appreciated as I don't want to throw my computer
through
the wall! :P
- Brian Ganninger
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.