• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: My app breaks when moved while running
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: My app breaks when moved while running


  • Subject: Re: My app breaks when moved while running
  • From: Jens Alfke <email@hidden>
  • Date: Fri, 8 Feb 2008 09:11:13 -0800


On 8 Feb '08, at 4:42 AM, Gregory Weston wrote:

While the raw effort *is* probably significant, the solution seems fairly straightforward. Instead of relying on cached paths (or whatever static structure is underlying these problems), the bundle mechanisms could be caching aliases.

That's a possibility. Aliases don't work on all types of filesystems, though — IIRC, NFS is one that doesn't support them. SMB might be another; I'm not sure.


There are significant numbers of Macs being used in enterprise / higher-ed environments where apps or user accounts live on such file servers. In the past, that's been given as a rationale for not adding low-level OS features/improvements, such as this, that depend on filesystem functionality that isn't universally available.

Another issue with caching aliases is that it's prone to race conditions. At some point you have to dereference the alias into a path, and then use the path. If the app moves in between those two moments, the attempt to use the path will fail.

In an ideal world users should be able to move apps willy-nilly, but I have to say I've never heard of a case where this actually caused a problem in the real world. Moving documents is a lot more common, so NSDocument does have support for tracking file movement.

—Jens_______________________________________________

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


  • Follow-Ups:
    • Re: My app breaks when moved while running
      • From: "Kyle Sluder" <email@hidden>
References: 
 >Re: My app breaks when moved while running (From: Gregory Weston <email@hidden>)

  • Prev by Date: Re: Catching Cocoa application Crash
  • Next by Date: Re: Encryption Frameworks in Cocoa
  • Previous by thread: Re: My app breaks when moved while running
  • Next by thread: Re: My app breaks when moved while running
  • Index(es):
    • Date
    • Thread