|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #26345 ord() crashes when passing '|' char
Submitted: 2003-11-21 05:02 UTC Modified: 2003-12-01 03:15 UTC
From: jaime dot lopez at iic dot uam dot es Assigned:
Status: No Feedback Package: Reproducible crash
PHP Version: 4.3.2 OS: AIX
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: jaime dot lopez at iic dot uam dot es
New email:
PHP Version: OS:


 [2003-11-21 05:02 UTC] jaime dot lopez at iic dot uam dot es
Apache process hangs out when calling ord() with reproducible arguments.

Reproduce code:
function isalpha( $char )
  return( (ord($char) >= ord("a") and ord($char) <= ord("z")) ||
  (ord($char) >= ord("A") and ord($char) <= ord("Z"))  );

echo is_alpha('|') ;

... PHP hangs ...

Expected result:

Actual result:
nothing ( php hangs calling ord() )


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2003-11-21 05:38 UTC]
strangely, I had a similar sounding problem using:

if (ord($word{0}) >= 127) {

under PHP 5 the other day.
 [2003-12-01 03:15 UTC]
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.

PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Tue Aug 09 01:05:44 2022 UTC