-rw-r--r-- | libopie/pim/otimezone.cpp | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/libopie/pim/otimezone.cpp b/libopie/pim/otimezone.cpp index b2bd3aa..34659c3 100644 --- a/libopie/pim/otimezone.cpp +++ b/libopie/pim/otimezone.cpp @@ -18,2 +18,3 @@ namespace { QCString org = ::getenv( "TZ" ); +#ifndef Q_OS_MACX // Following line causes bus errors on Mac ::setenv( "TZ", zone.latin1(), true ); @@ -23,2 +24,6 @@ namespace { ::setenv( "TZ", org, true ); +#else +#warning "Need a replacement for MacOSX!!" + tm* broken = ::localtime( &t ); +#endif @@ -43,2 +48,3 @@ namespace { QCString org = ::getenv( "TZ" ); +#ifndef Q_OS_MACX // Following line causes bus errors on Mac ::setenv( "TZ", str.latin1(), true ); @@ -48,3 +54,6 @@ namespace { ::setenv( "TZ", org, true ); - +#else +#warning "Need a replacement for MacOSX!!" + time_t ti = ::mktime( &broken ); +#endif return ti; |