From: Anatol Belski Date: Sun, 10 May 2015 19:16:56 +0000 (+0200) Subject: fix timezone usage in soap for vc14 X-Git-Tag: PRE_PHP7_NSAPI_REMOVAL~50 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f22a5bd710ca62175275e0cd5d5143c010e94bf1;p=php fix timezone usage in soap for vc14 --- diff --git a/ext/soap/php_encoding.c b/ext/soap/php_encoding.c index 9c25067f42..96207f7975 100644 --- a/ext/soap/php_encoding.c +++ b/ext/soap/php_encoding.c @@ -2905,7 +2905,7 @@ static xmlNodePtr to_xml_datetime_ex(encodeTypePtr type, zval *data, char *forma #ifdef HAVE_TM_GMTOFF snprintf(tzbuf, sizeof(tzbuf), "%c%02d:%02d", (ta->tm_gmtoff < 0) ? '-' : '+', abs(ta->tm_gmtoff / 3600), abs( (ta->tm_gmtoff % 3600) / 60 )); #else -# if defined(__CYGWIN__) || defined(NETWARE) +# if defined(__CYGWIN__) || defined(NETWARE) || (defined(PHP_WIN32) && defined(_MSC_VER) && _MSC_VER >= 1900) snprintf(tzbuf, sizeof(tzbuf), "%c%02d:%02d", ((ta->tm_isdst ? _timezone - 3600:_timezone)>0)?'-':'+', abs((ta->tm_isdst ? _timezone - 3600 : _timezone) / 3600), abs(((ta->tm_isdst ? _timezone - 3600 : _timezone) % 3600) / 60)); # else snprintf(tzbuf, sizeof(tzbuf), "%c%02d:%02d", ((ta->tm_isdst ? timezone - 3600:timezone)>0)?'-':'+', abs((ta->tm_isdst ? timezone - 3600 : timezone) / 3600), abs(((ta->tm_isdst ? timezone - 3600 : timezone) % 3600) / 60));