Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:22497 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 75622 invoked by uid 1010); 17 Mar 2006 07:34:29 -0000 Delivered-To: ezmlm-scan-internals@lists.php.net Delivered-To: ezmlm-internals@lists.php.net Received: (qmail 75607 invoked from network); 17 Mar 2006 07:34:29 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 17 Mar 2006 07:34:29 -0000 X-Host-Fingerprint: 204.127.192.83 rwcrmhc13.comcast.net NetCache Data OnTap 5.x Received: from ([204.127.192.83:64575] helo=rwcrmhc13.comcast.net) by pb1.pair.com (ecelerity 2.0 beta r(6323M)) with SMTP id B0/5F-55982-3866A144 for ; Fri, 17 Mar 2006 02:34:28 -0500 Received: from [192.168.1.130] (c-69-141-229-108.hsd1.nj.comcast.net[69.141.229.108]) by comcast.net (rwcrmhc13) with SMTP id <20060317073425m13005kqj3e>; Fri, 17 Mar 2006 07:34:25 +0000 To: internals Content-Type: text/plain Date: Fri, 17 Mar 2006 02:28:13 -0500 Message-ID: <1142580493.27317.30.camel@localhost> Mime-Version: 1.0 X-Mailer: Evolution 2.2.1.1 Content-Transfer-Encoding: 7bit Subject: PHP 5.1.2 segfaults in get_timezone_info From: abaker@php.net (Al Baker) Hi, We're trying to run php 5.1.2 on Windriver Linux (PPC) -- unsupported I know -- and most things appear to be working. However when trying to use Smarty (which has calls to date functions for caching), PHP segfaults in time(). Running PHP in GDB shows the trace of failing in memcpy and malloc as called from timelib_parse_tzfile (timezone=0x30029008 "", tzdb=0x179018c) at ... ext/date/lib/parse_tz.c:91 The rest of the stack is full of calls to ext/date/php_date.c:319 and gdb eventually says Previous frame inner to this frame (corrupt stack?) Looking at strace, Smarty_Compiler.class.php goes through and eventually does time(NULL) = 138027 a couple times and then mmap(NULL, 100667392, PROT_READ|PROT_WRITE, MAP_PRIVATE,MAP_ANONYMOUS, -1, 0) = 0x30029000 followed by the SIGSEGV @ 0. Setting date.timezone in php.ini doesn't solve the problem. WindRiver keeps its timezone files in /usr/share/zoneinfo (e.g. /usr/share/zoneinfo/GMT). There is also a localtime time zone file in /etc. I don't know if this is a php bug, or perhaps pilot-error on my part on either WindRiver Linux configuration or cross-compiling PHP. Thanks, Al