|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #72003 mb_strpos argument error not correct
Submitted: 2016-04-11 15:45 UTC Modified: 2016-04-11 18:05 UTC
From: mattkasper at gmail dot com Assigned:
Status: Closed Package: mbstring related
PHP Version: 7.0.5 OS: Suse 12 on s390
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.
Block user comment
Status: Assign to:
Bug Type:
From: mattkasper at gmail dot com
New email:
PHP Version: OS:


 [2016-04-11 15:45 UTC] mattkasper at gmail dot com
mb_strpos takes $needle, $haystack, $offset and $encoding as arguments but an error is thrown complaining of an empty delimiter when valid arguments are passed.

Test script:
var_dump(mb_strpos("test", "test", 0, "UTF-8"));

Expected result:

Actual result:
Warning: MB_strpos(): Empty delimiter in test.php on line 2


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2016-04-11 18:04 UTC] mattkasper at gmail dot com
Apparently we were running 7.0.2 (not 7.0.5) and after updating to 7.0.5, the issue was resolved and mb functions were working correctly.
 [2016-04-11 18:05 UTC] mattkasper at gmail dot com
-Status: Open +Status: Closed
 [2016-04-11 18:05 UTC] mattkasper at gmail dot com
Resolved in 7.0.5.
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Feb 26 13:01:27 2024 UTC