I keep getting this error. I'm uploading via ftp to a server. It works fine and uploads completely while running in the simulator, but when I provision it on my iPhone, it says:
Error Occurred. Upload failed: The operation couldn’t be completed. (Cocoa error 260.)
Any suggestions? I've been debugging and researching for hours on end and can't figure this out. I've tried cleaning targets, resetting device, resetting xcode.
One thing I narrowed down was:
NSError *attributesError = nil;
NSDictionary *fileAttributes = [[NSFileManager defaultManager] attributesOfItemAtPath:self.filePath error:&attributesError];
if (attributesError) {
[self failWithError:attributesError];
return;
}
In the device attributesError is true, in the simulator it is false