• 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: Multiple instances of [NSUserDefaults standardUserDefaults]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Multiple instances of [NSUserDefaults standardUserDefaults]


  • Subject: Re: Multiple instances of [NSUserDefaults standardUserDefaults]
  • From: Zach Drayer <email@hidden>
  • Date: Sat, 23 Oct 2010 19:52:20 -0500

Have you tried calling -synchronize before accessing user defaults to get a value (or after accessing them to set a value)? It should force a synchronization of all the defaults to disk.

- Zach

On Oct 23, 2010, at 5:47 AM, Chris Idou wrote:

>
>
> I'm printing out the address of [NSUserDefaultsstandardUserDefaults] in several
> places in my app, and getting a different result! This is causing me problems.
>
> I'm using a plugin architecture, so I'm guessing this has something to do with
> it, but even so, I haven't seen anything like this happen before as far as being
> multiple instances of global variables.
>
> Has anyone got any thoughts?
>
>
>
> _______________________________________________
>
> 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

_______________________________________________

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

References: 
 >Multiple instances of [NSUserDefaults standardUserDefaults] (From: Chris Idou <email@hidden>)

  • Prev by Date: Re: Multiple instances of [NSUserDefaults standardUserDefaults]
  • Next by Date: fork/exec vs NSTask
  • Previous by thread: Re: Multiple instances of [NSUserDefaults standardUserDefaults]
  • Next by thread: DO over unnamed sockets
  • Index(es):
    • Date
    • Thread