diff options
author | Tor Lillqvist <tml@novell.com> | 2006-06-16 10:32:15 +0000 |
---|---|---|
committer | Tor Lillqvist <tml@src.gnome.org> | 2006-06-16 10:32:15 +0000 |
commit | 9499678f55b7774a02a96b530be0834fc0fc477c (patch) | |
tree | 2138a8eb38cdd2762599be9b703a46c2d3a6b37c | |
parent | 195144433cff51c6b67daa7a3f9fcc723f0a15fd (diff) | |
download | evolution-data-server-9499678f55b7774a02a96b530be0834fc0fc477c.tar.gz |
Add gmtime_r() macro implementation for Win32.
2006-06-16 Tor Lillqvist <tml@novell.com>
* backends/groupwise/e-cal-backend-groupwise.c: Add gmtime_r()
macro implementation for Win32.
-rw-r--r-- | calendar/ChangeLog | 5 | ||||
-rw-r--r-- | calendar/backends/groupwise/e-cal-backend-groupwise.c | 10 |
2 files changed, 15 insertions, 0 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog index 8ab0f2346..5c17596d4 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,8 @@ +2006-06-16 Tor Lillqvist <tml@novell.com> + + * backends/groupwise/e-cal-backend-groupwise.c: Add gmtime_r() + macro implementation for Win32. + 2006-06-15 Andre Klapper <a9016009@gmx.de> * libecal/e-cal.c: diff --git a/calendar/backends/groupwise/e-cal-backend-groupwise.c b/calendar/backends/groupwise/e-cal-backend-groupwise.c index f073a899b..6d62fd32c 100644 --- a/calendar/backends/groupwise/e-cal-backend-groupwise.c +++ b/calendar/backends/groupwise/e-cal-backend-groupwise.c @@ -49,6 +49,16 @@ #define O_BINARY 0 #endif +#ifdef G_OS_WIN32 +/* Undef the similar macro from pthread.h, it doesn't check if + * gmtime() returns NULL. + */ +#undef gmtime_r + +/* The gmtime() in Microsoft's C library is MT-safe */ +#define gmtime_r(tp,tmp) (gmtime(tp)?(*(tmp)=*gmtime(tp),(tmp)):0) +#endif + /* Private part of the CalBackendGroupwise structure */ struct _ECalBackendGroupwisePrivate { /* A mutex to control access to the private structure */ |