Re: renaming directories and moving files into them (NSFileManager)
Re: renaming directories and moving files into them (NSFileManager)
- Subject: Re: renaming directories and moving files into them (NSFileManager)
- From: Andy Lee <email@hidden>
- Date: Sun, 17 Apr 2011 01:58:01 -0400
On Apr 15, 2011, at 1:47 AM, Scott Anguish wrote:
> if (foundRange.location > 0) { // should be comparing to NSNotFound, but that failed miserably.
> newShootPath=[shootPath stringByAppendingString:@“-APPL”];
> // make sure I’ve not already done this
> if (![self directoryExists:newShootPath]) {
>
> success=[fileManager moveItemAtPath:shootPath toPath:newShootPath error:&theError];
> NSLog(@"should be moving - %d",success);
> //success is true!
>
> // make the newShootPath, the shootPath for other files
> [shootPath autorelease];
> shootPath=[newShootPath retain];
This looks odd to me. Isn't shootPath going to become /tmp/boo/Friday-APPL, then /tmp/boo/Friday-APPL-APPL, etc.?
--Andy
_______________________________________________
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