Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
freebsd
GitHub Repository: freebsd/freebsd-ports-gnome
Path: blob/main/net-im/jabberd/files/patch-sm__mod_iq_time.c
16124 views
1
--- sm/mod_iq_time.c.orig 2016-02-09 09:47:02 UTC
2
+++ sm/mod_iq_time.c
3
@@ -77,7 +77,7 @@ static mod_ret_t _iq_time_pkt_sm(mod_instance_t mi, pk
4
5
datetime_out(t, dt_DATETIME, buf, 64);
6
nad_insert_elem(pkt->nad, 2, NAD_ENS(pkt->nad, 1), "utc", buf);
7
-#ifdef HAVE_TZSET
8
+#ifdef HAVE_TZNAME
9
snprintf(buf, 64, "%+03d:%02d", -((int)timezone)/(60*60), -((int)timezone)%(60*60));
10
#else
11
snprintf(buf, 64, "%+03d:%02d", (int) tm->tm_gmtoff/(60*60), (int) tm->tm_gmtoff%(60*60));
12
13