Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:55023 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 42586 invoked from network); 31 Aug 2011 05:08:18 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 31 Aug 2011 05:08:18 -0000 Authentication-Results: pb1.pair.com header.from=smalyshev@sugarcrm.com; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=smalyshev@sugarcrm.com; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain sugarcrm.com designates 67.192.241.203 as permitted sender) X-PHP-List-Original-Sender: smalyshev@sugarcrm.com X-Host-Fingerprint: 67.192.241.203 smtp203.dfw.emailsrvr.com Linux 2.6 Received: from [67.192.241.203] ([67.192.241.203:45187] helo=smtp203.dfw.emailsrvr.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 7D/DC-50561-1C1CD5E4 for ; Wed, 31 Aug 2011 01:08:18 -0400 Received: from localhost (localhost.localdomain [127.0.0.1]) by smtp10.relay.dfw1a.emailsrvr.com (SMTP Server) with ESMTP id 7C7631B8173; Wed, 31 Aug 2011 01:08:15 -0400 (EDT) X-Virus-Scanned: OK Received: by smtp10.relay.dfw1a.emailsrvr.com (Authenticated sender: smalyshev-AT-sugarcrm.com) with ESMTPSA id F40E81B8062; Wed, 31 Aug 2011 01:08:14 -0400 (EDT) Message-ID: <4E5DC1BE.1000800@sugarcrm.com> Date: Tue, 30 Aug 2011 22:08:14 -0700 Organization: SugarCRM User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:6.0) Gecko/20110812 Thunderbird/6.0 MIME-Version: 1.0 To: Rasmus Lerdorf CC: PHP Internals , "jeraimee@php.net" References: <4E5DACD6.1000002@sugarcrm.com> <4E5DB4E8.4030509@lerdorf.com> <4E5DBE4A.6010403@sugarcrm.com> In-Reply-To: <4E5DBE4A.6010403@sugarcrm.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PHP-DEV] 5.4 beta & tests From: smalyshev@sugarcrm.com (Stas Malyshev) Hi! On 8/30/11 9:53 PM, Stas Malyshev wrote: > strftime() on Mac seems to ignore timezone arguments in struct tm for > some reason and uses environment TZ instead. Not sure how to address that. Looking into Mac strftime sources, it says this: ** C99 says that the UTC offset must ** be computed by looking only at ** tm_isdst. This requirement is ** incorrect, since it means the code ** must rely on magic (in this case ** altzone and timezone), and the ** magic might not have the correct ** offset. Doing things correctly is ** tricky and requires disobeying C99; ** see GNU C strftime for details. ** For now, punt and conform to the ** standard, even though it's incorrect. Which means, since we can't touch the environment in php_date.c code, we have to set TZ env variable for the test to pass, and strftime for Mac is dependent on TZ env and we can't do a thing about it as it seems. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227