ac0075c2b5
Linphone 3.9.0 Ortp 0.25.0 + bump PORTREVISION on dependent ports (devel/libosmo-abis) Libbzrtp 1.0.3 Belle-sip (fix files/patch-src-belle_sip_headers_impl.c) Mediastreamer 2.12.0 MS plugins (msbcg729 1.0.1, msilbc 2.1.2, msopenh264 1.1.1, msx264 1.5.2)
35 lines
987 B
C
35 lines
987 B
C
--- coreapi/presence.c.orig 2015-10-23 09:10:07 UTC
|
|
+++ coreapi/presence.c
|
|
@@ -157,11 +157,6 @@ static void presence_activity_delete(Lin
|
|
static time_t parse_timestamp(const char *timestamp) {
|
|
struct tm ret;
|
|
time_t seconds;
|
|
-#ifdef LINPHONE_WINDOWS_UNIVERSAL
|
|
- long adjust_timezone;
|
|
-#else
|
|
- time_t adjust_timezone;
|
|
-#endif
|
|
|
|
memset(&ret, 0, sizeof(ret));
|
|
sscanf(timestamp, "%d-%d-%dT%d:%d:%d",
|
|
@@ -169,17 +164,12 @@ static time_t parse_timestamp(const char
|
|
ret.tm_mon--;
|
|
ret.tm_year -= 1900;
|
|
ret.tm_isdst = 0;
|
|
- seconds = mktime(&ret);
|
|
+ seconds = timegm(&ret);
|
|
if (seconds == (time_t)-1) {
|
|
- ms_error("mktime() failed: %s", strerror(errno));
|
|
+ ms_error("timegm() failed: %s", strerror(errno));
|
|
return (time_t)-1;
|
|
}
|
|
-#ifdef LINPHONE_WINDOWS_UNIVERSAL
|
|
- _get_timezone(&adjust_timezone);
|
|
-#else
|
|
- adjust_timezone = timezone;
|
|
-#endif
|
|
- return seconds - (time_t)adjust_timezone;
|
|
+ return seconds;
|
|
}
|
|
|
|
char * linphone_timestamp_to_rfc3339_string(time_t timestamp) {
|