|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #2673 calendar functions cause php crash when passed a number that is too big
Submitted: 1999-11-05 19:19 UTC Modified: 2002-06-16 14:18 UTC
From: agent86 at earthling dot net Assigned:
Status: Not a bug Package: Misbehaving function
PHP Version: 3.0.11 OS: NT4 sp5
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Bug Type:
From: agent86 at earthling dot net
New email:
PHP Version: OS:


 [1999-11-05 19:19 UTC] agent86 at earthling dot net
The following script will crash php every time.  It is actually any of the calendar functions that cause the crash.  I tried most of the jd to something functions.

This causes a crash.  The dialog box title is: OleMainThreadWndName:php.exe - Application Error

The dialog box contents: 
The instruction at "0x0042447d" referenced memory at "0x00000000". The memory could not be "read".  Click OK to terminate the application

I realize I am passing a timestamp instead of julian count.  Originally I did this unintentionally.  What my error exposed is that passing a julian day count that is very large to the jdtosomething functions will cause them to crash php instead of merely generating an error message.

This occurs whether the module is loaded in php.ini or dynamically with dl(). I also get the same crash when I run the script in a dos box (no web server).

Not a serious bug, but it does cause a crash (at least for the NT version) if you pass a large number (like a timestamp) to the calendar functions.



Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-06-16 14:18 UTC]
Thank you for taking the time to report a problem with PHP.
Unfortunately, PHP 3 is no longer supported. Please download
the latest version of PHP 4 from

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Wed Nov 25 04:01:23 2020 UTC