|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #35412 go-pear.bat fails if mbstring is configured at php.ini
Submitted: 2005-11-26 20:14 UTC Modified: 2006-01-08 15:55 UTC
From: mauroi at digbang dot com Assigned: cellog (profile)
Status: Closed Package: *General Issues
PHP Version: 5.1.0 OS: win32
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: mauroi at digbang dot com
New email:
PHP Version: OS:


 [2005-11-26 20:14 UTC] mauroi at digbang dot com
I have the following statements in my php.ini :

When I try to run go-pear.bat I get the error:

"Warning: gzinflate(): data error in C:\Program Files\PHP5\PEAR\go-pear.phar on line 404

Notice: Undefined variable: size in C:\Program Files\PHP5\PEAR\go-pear.phar on l
ine 407

Fatal error: Not valid gz file (size error  != 0) in C:\Program Files\PHP5\PEAR\go-pear.phar on line 408".

If I remove those php.ini lines everything works ok.



Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2005-11-26 20:24 UTC]
Assigned to the maintainer.
 [2005-11-26 20:25 UTC]
If you change mbstring.func_overload=6 to mbstring.func_overload=0, does the problem go away?
 [2005-11-26 21:02 UTC] mauroi at digbang dot com
Yes. It works if I disable overloading.
When I'm working with lobs (binary data in general) under this configuration I use mb_strlen($str, 'ASCII') instead of strlen($str). Otherwise, the variable would be treated as string and any unicode escape sequence would generate an error.
Maybe a function called something like 'bytecount' could help to avoid this situation.

 [2005-11-26 21:06 UTC] mauroi at digbang dot com
Another workaround is to add a '-n' to the cli invocation inside of go-pear.bat
That way no php.ini is used.
 [2005-11-28 01:38 UTC]
I think I'll opt for door #3 which is to insert:

if (function_exists('mb_internal_encoding')) {

at the top of the .phar
 [2005-11-28 01:43 UTC]
Please try using this CVS snapshot:
For Windows:

when you do this, please grab go-pear.phar directly from - and please do this no sooner than 1 hour after this message, as is synced once per hour with cvs
 [2005-12-06 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 [2006-01-08 15:55 UTC] mauroi at digbang dot com
PHP Copyright © 2001-2021 The PHP Group
All rights reserved.
Last updated: Mon Sep 20 18:03:39 2021 UTC