trunk/branch integration: VxWorks & Wince

This commit is contained in:
Marian Krivos
2011-08-23 07:13:59 +00:00
parent 35f44e5a2d
commit fd733bcca4
2 changed files with 138 additions and 17 deletions

View File

@@ -49,13 +49,13 @@ public:
{
tzset();
}
int timeZone()
{
#if defined(__APPLE__) || defined(__FreeBSD__) // no timezone global var
std::time_t now = std::time(NULL);
struct std::tm t;
gmtime_r(&now, &t);
int timeZone()
{
#if defined(__APPLE__) || defined(__FreeBSD__) || defined(POCO_ANDROID) // no timezone global var
std::time_t now = std::time(NULL);
struct std::tm t;
gmtime_r(&now, &t);
std::time_t utc = std::mktime(&t);
return now - utc;
#elif defined(__CYGWIN__)