-
Notifications
You must be signed in to change notification settings - Fork 49
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
timeutils: fix newer/older comparison with TZ aware datetime
Blindly replacing the timezone information from a timestamp does not make it correctly UTC. It just strips information away, and therefore does not make any valid comparison. This fixes the comparison function by normalizing the timestamps to UTC before doing any comparison. Change-Id: I3a1b1eae497200ca951ccb003dbcc75fb75380fa
- Loading branch information
Showing
2 changed files
with
16 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters