Re: iOS 7/8 sandboxing question. Path to Documents folder changing on every app launch?
Re: iOS 7/8 sandboxing question. Path to Documents folder changing on every app launch?
- Subject: Re: iOS 7/8 sandboxing question. Path to Documents folder changing on every app launch?
- From: Mike Abdullah <email@hidden>
- Date: Mon, 06 Apr 2015 16:45:16 +0100
> On 6 Apr 2015, at 15:52, Alex Zavatone <email@hidden> wrote:
>
> I'm running into an interesting issue I'm trying to track down under iOS 7 and 8. (Xcode 6.2, Mac OS 10.10.2)
>
> Our app downloads files and saves them within the app for display later when the user wants to bring them up.
>
> It appears that after the first launch, the files can't be found.
>
> Does the application path change upon subsequent launches as a result of iOS sandboxing?
>
> I'm looking into how we are getting our files' path at the moment and I just wanted to know for sure if I should expect the file path to the application's Documents folder to change under iOS 7/8 under each launch.
I’m pretty sure this is the intended behaviour of the simulator, to show up brittleness in developers’ filesystem code.
Sounds like you’re storing absolute paths to the files at the moment? If so, that’s wrong. Apple’s perfectly entitled to place your app’s Documents folder wherever they feel like. You should be storing some sort of _relative_ paths within the folder instead.
_______________________________________________
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