linux - Adjust Time to Daylight Saving for localtime C++ -
i have piece of optimized function gmt time. convert local time. want call localtime , gmtime function once adjust time localtime calling localtime , gmtime multiple times defeat purpose of using optimized function. however, problem how adjust localtime when there daylight saving? ideas on that?
thanks.
i've never noticed performance issues fetching time. problem in code?
in case, simplest solution compute offset utc-to-local, , recompute if hour different when offset computed.
Comments
Post a Comment