#23457 [Fbk->NoF]: PHP crashes
| From: | sniper@php.net | Date: | Fri, 09 May 2003 13:02:14 +0000 |
| Subject: | #23457 [Fbk->NoF]: PHP crashes | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-39385@lists.php.net to get a copy of this message | ||
ID: 23457
Updated by: sniper@php.net
Reported By: xdanny at email dot cz
-Status: Feedback
+Status: No Feedback
Bug Type: Date/time related
-Operating System: ANY
+Operating System: win32
PHP Version: 4.3.2RC1
New Comment:
No feedback was provided. The bug is being suspended because
we assume that you are no longer experiencing the problem.
If this is not the case and you are able to provide the
information that was requested earlier, please do so and
change the status of the bug back to "Open". Thank you.
Previous Comments:
------------------------------------------------------------------------
[2003-05-04 08:36:10] sniper@php.net
Please try using this CVS snapshot:
http://snaps.php.net/php4-STABLE-latest.tar.gz
For Windows:
http://snaps.php.net/win32/php4-win32-STABLE-latest.zip
------------------------------------------------------------------------
[2003-05-04 05:27:04] derick@php.net
It's not verified on Linux where it doesnt crash. It does crash on
Windows though, but not when run from within the MS VC debugger...
------------------------------------------------------------------------
[2003-05-04 05:26:31] nicos@php.net
Note that you will be get a notice if you use error_reporting(E_ALL);
:
Notice: Use of undefined constant DATEFORMAT - assumed 'DATEFORMAT' in
- on line 3
-(3) : Notice - Use of undefined constant DATEFORMAT - assumed
'DATEFORMAT'
------------------------------------------------------------------------
[2003-05-04 05:17:09] nicos@php.net
This probably happens because the engine accepts unquoted word when
it's alone. It takes it as
$today = date('DATEFORMAT',$timestamp);
Yes this is ugly but I don't think this can be changed if we dont want
to break BC again.
Btw if you try
$today = date(DATEFORMAT LOL,$timestamp);
It will parser error but not with only one word.
------------------------------------------------------------------------
[2003-05-04 05:13:08] nicos@php.net
I have the same problem with PHP5:
[Sun May 4 - 12:08:17 - nicos ~]$ php
<?php
//define(DATEFORMAT, 'Y/m/d');
$timestamp = Time();
$today = Date(DATEFORMAT, $timestamp);
echo "Hi, today is $today";
?>
Hi, today is SunPMCESTEMay+0200RMayPMCEST
[Sun May 4 - 12:08:19 - nicos ~]$
PHP 5.0.0-dev (cli) (built: Apr 27 2003 15:59:15)
Copyright (c) 1997-2003 The PHP Group
Zend Engine v2.0.0-dev, Copyright (c) 1998-2003 Zend Technologies
Same with :
PHP 4.3.2-RC1 (cli) (built: May 1 2003 19:59:00)
Copyright (c) 1997-2003 The PHP Group
Zend Engine v1.3.0, Copyright (c) 1998-2003 Zend Technologies
Shouldn't it print an E_FATAL when we're using an undefined constant?
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/23457
--
Edit this bug report at http://bugs.php.net/?id=23457&edit=1