projects
/
birthday
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
981a007
)
Fill DST flag in birhday structs to fix calculation of age.
author
Roman Moravcik
<roman.moravcik@gmail.com>
Thu, 14 Oct 2010 10:43:01 +0000
(12:43 +0200)
committer
Roman Moravcik
<roman.moravcik@gmail.com>
Thu, 14 Oct 2010 10:43:01 +0000
(12:43 +0200)
src/birthday.c
patch
|
blob
|
history
diff --git
a/src/birthday.c
b/src/birthday.c
index
b424e74
..
8799859
100644
(file)
--- a/
src/birthday.c
+++ b/
src/birthday.c
@@
-275,6
+275,7
@@
calc_age (EContactDate *bdate, time_t current_date)
bday_tm.tm_mday = bdate->day;
bday_tm.tm_mon = bdate->month - 1;
bday_tm.tm_year = current_date_tm->tm_year;
bday_tm.tm_mday = bdate->day;
bday_tm.tm_mon = bdate->month - 1;
bday_tm.tm_year = current_date_tm->tm_year;
+ bday_tm.tm_isdst = current_date_tm->tm_isdst;
if (mktime (&bday_tm) > current_date) {
age = (current_date_tm->tm_year + 1900) - bdate->year - 1;
if (mktime (&bday_tm) > current_date) {
age = (current_date_tm->tm_year + 1900) - bdate->year - 1;