NSTimezone and offset
NSTimezone and offset
- Subject: NSTimezone and offset
- From: Lorenzo Thurman <email@hidden>
- Date: Wed, 04 Sep 2013 23:21:03 -0500
Im working with NSTimezone and I need to get the current timezone offset, but I'm finding this more difficult than I think it should be. I thought it might just be the way I'm looking at things, but I don't think so.
If create an NSTimezone object and then send that object a daylightSavingTimeOffset message, I get back, for Chicago, 3600. This is wrong, at least for my purposes, for two reasons:
1) The offset should negative.
2) Chicago is currently observing DST
The value I would expect to see returned should be -3000. I get why the value 3600 is correct at least with respect to the magnitude, as I can see I have this link setup for my system:
/etc/localtime -> /usr/share/zoneinfo/America/Chicago
But, why is it not negative? How do I get the correct offset.
TIA
_______________________________________________
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