php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #3573 Comparison of string "inf" fails
Submitted: 2000-02-22 14:28 UTC Modified: 2000-02-25 23:10 UTC
From: stefan at fostam dot franken dot de Assigned:
Status: Closed Package: Misbehaving function
PHP Version: 4.0 Beta 3 OS: RedHat Linux 6.0 Intel
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: stefan at fostam dot franken dot de
New email:
PHP Version: OS:

 

 [2000-02-22 14:28 UTC] stefan at fostam dot franken dot de
I found this misbehaviour in several versions (3.0.12, 4b1 through 4b4):

if ("inf" == "inf") {
  print "OK";
}

if ("inf" != "inf") {
  print "BUG";
}

Comparing the string "inf" with itself (either literal or by variables) returns false,
and vice versa comparing with "!=" true. So far, "inf" is the only string with that
misbehaviour I've detected.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-02-25 23:10 UTC] zeev at cvs dot php dot net
Fixed
 [2000-02-25 23:10 UTC] zeev at cvs dot php dot net
Fixed
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sun Jun 02 00:01:30 2024 UTC