php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #59039 Bloomy always returns true for empty strings
Submitted: 2010-01-22 05:30 UTC Modified: 2017-04-01 19:37 UTC
Votes:2
Avg. Score:3.5 ± 0.5
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: contato at sanainside dot com Assigned:
Status: Wont fix Package: bloomy (PECL)
PHP Version: 5.3.0 OS: Centos 5.2
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 you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: contato at sanainside dot com
New email:
PHP Version: OS:

 

 [2010-01-22 05:30 UTC] contato at sanainside dot com
Description:
------------
For every bloomfilter i create with this extensions, the method has() always returns true when passed an empty string. btw, thanks for your time doing it, it's really useful.

Reproduce code:
---------------
$bf = new BloomFilter(3, 0.0001);
$bf->add("foo");
$bf->add("bar");
$bf->add("xyz");

var_dump($bf->has("foo"));
var_dump($bf->has("blabla"));
var_dump($bf->has(""));

Expected result:
----------------
true
false
false

Actual result:
--------------
true
false
true

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2017-04-01 19:37 UTC] tpunt@php.net
-Status: Open +Status: Wont fix
 [2017-04-01 19:37 UTC] tpunt@php.net
Due to this extension not seeing any activity since 2009, this issue will not be fixed. We are therefore closing this now.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Dec 27 06:01:29 2024 UTC