pidgin: 5387bc28: Allow a 'Z' (UTC) TZ in strings passed t...

qulogic at pidgin.im qulogic at pidgin.im
Sat Jun 14 04:10:53 EDT 2008


-----------------------------------------------------------------
Revision: 5387bc28fa09b238593c3dc292863ec3ce5f3c4e
Ancestor: 7777eca09d173823e2c26e8363ec73fffc6035b9
Author: qulogic at pidgin.im
Date: 2008-06-14T04:50:35
Branch: im.pidgin.pidgin
URL: http://d.pidgin.im/viewmtn/revision/info/5387bc28fa09b238593c3dc292863ec3ce5f3c4e

Modified files:
        libpurple/util.c

ChangeLog: 

Allow a 'Z' (UTC) TZ in strings passed to purple_str_to_time. Used for 
parsing (some) MSN SOAP timestamps.

Plucked from im.pidgin.cpw.qulogic.msn, approved by rlaager,
applied changes from 738e1d83d6a690135e101c9612aee628c1b65601
             through cc1fdbd7d5ce3915a5d7ad6920066f5951a29e23

-------------- next part --------------
============================================================
--- libpurple/util.c	771fe71d7e19e96f83034f3bf88ec80656113978
+++ libpurple/util.c	852ffed93f237b177f8f88ce0b49aa6389fda2cd
@@ -832,6 +832,11 @@ purple_str_to_time(const char *timestamp
 				if (offset_positive)
 					tzoff *= -1;
 			}
+			else if ((*c == 'Z') && (c = c + 1))
+			{
+				/* 'Z' = Zulu = UTC */
+				tzoff = 0;
+			}
 			else if (utc)
 			{
 				static struct tm tmptm;


More information about the Commits mailing list