rentzsch.com: tales from the red shed

Date Math is Hard, Let's Go Shopping

Cocoa
Murphy's Law strikes again! What are the chances I'd be writing date math code that roundtrips the system, right when Daylight Savings Time kicks in?

For the last half hour or so, I've been trying to figure out why 1 am + 1 hour == 1 am! Why, it's almost as if the operating system is purposely shifting the time backwards on me! Finally the time zone dawned on me...

Sunday, October 31, 2004
01:08 AM