php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #34111 Several tests w/string and zlib-based functions fail w/Japanese mbstring
Submitted: 2005-08-12 23:46 UTC Modified: 2005-08-20 01:00 UTC
From: RVaughn at pheedo dot com Assigned:
Status: No Feedback Package: mbstring related
PHP Version: 4.4.0 OS: RHEL 3.0
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: RVaughn at pheedo dot com
New email:
PHP Version: OS:

 

 [2005-08-12 23:46 UTC] RVaughn at pheedo dot com
Description:
------------
With PHP 4.4 on Red Hat Enterprise 3.0, several string and zlib-based function calls fail when the 'mbstring' extension is activated, but work when it is turned off.  These are shown in the test suites, which produce a set of failures when the 'mbstring.encoding' parameter is set to "Japanese" in the /etc/php.ini file, but when it is changed to "English" or "Neutral", the test suite returns different results, with none of the string or zlib functions failing, but an XML-related routine failing instead.

My guess is that the 'mbstring' stuff is either broken or does not fully support all the possible character & string-related functions or does not overload them properly.

My configuration for the build:

./configure 2>configure.err '--host=i386-redhat-linux' '--build=i386-redhat-linux' '--target=i386-redhat-linux-gnu' '--cache-file=../config.cache' '--with-config-file-path=/etc' '--with-config-file-scan-dir=/etc/php.d' '--enable-force-cgi-redirect' '--disable-debug' '--enable-pic' '--disable-rpath' '--enable-inline-optimization' '--with-bz2' '--with-db4=/usr' '--with-curl' '--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-gd' '--enable-gd-native-ttf' '--without-gdbm' '--with-gettext' '--with-ncurses' '--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' '--with-png' '--with-aspell' '--with-regex=system' '--with-xml' '--with-expat-dir=/usr' '--with-dom=shared,/usr' '--with-dom-xslt=/usr' '--with-dom-exslt=/usr' '--with-xmlrpc=shared' '--with-pcre-regex=/usr' '--with-zlib' '--with-layout=GNU' '--enable-bcmath' '--enable-exif' '--enable-ftp' '--enable-magic-quotes' '--enable-safe-mode' '--enable-sockets' '--enable-sysvsem' '--enable-sysvshm' '--enable-discard-path' '--enable-track-vars' '--enable-trans-sid' '--disable-yp' '--enable-wddx' '--without-oci8' '--with-pear=/usr/share/pear' '--with-mysql=shared,/usr' '--with-snmp=shared,/usr' '--with-snmp=shared' '--enable-ucd-snmp-hack' '--with-unixODBC=shared' '--enable-memory-limit' '--enable-bcmath' '--enable-shmop' '--enable-calendar' '--enable-dbx' '--enable-dio' '--enable-mcal' '--enable-mbstring' '--enable-mbstr-enc-trans' '--enable-mbregex' '--without-ldap' '--without-imap' '--without-imap-ssl' '--without-kerberos' '--enable-mhash' '--with-apxs2=/usr/sbin/apxs' 

Reproduce code:
---------------
Build PHP 4.4 on an RHEL 3.0 system with the 'mbstring' extension turned on.  In the '/etc/php.ini' file set the line 'mbstring.encoding = Japanese' and you will get all the test failures outlined below.  Change it back to 'Neutral' or 'English' and the failures go away.  The following test scripts fail in "Japanese" setting:

ext/exif/tests/exif002.phpt
ext/standard/tests/strings/count_chars.phpt
ext/standard/tests/strings/strtoupper.phpt
ext/zlib/tests/001.phpt
ext/zlib/tests/002.phpt
ext/zlib/tests/003.phpt

Expected result:
----------------
This is the output of the 'make test' run if 'mbstring.encoding' is set to "Neutral" or "English" in the /etc/php.ini file:

=====================================================================
FAILED TEST SUMMARY
---------------------------------------------------------------------
Bug #22414: passthru() does not read data correctly [ext/standard/tests/file/bug22414.phpt]
xml_parse_into_struct/umlauts in tags [ext/xml/tests/xml007.phpt]
=====================================================================


Actual result:
--------------
This is the output of the 'make test' run if 'mbstring.encoding' is set to "Japanese" in the /etc/php.ini file.  Nothing has been changed except that single setting in the php.ini file:

=====================================================================
FAILED TEST SUMMARY
---------------------------------------------------------------------
Check for exif_thumbnail [ext/exif/tests/exif002.phpt]
Bug #22414: passthru() does not read data correctly [ext/standard/tests/file/bug22414.phpt]
count_chars() function [ext/standard/tests/strings/count_chars.phpt]
Test strtoupper on non-ASCII characters [ext/standard/tests/strings/strtoupper.phpt]
gzdeflate()/gzinflate() [ext/zlib/tests/001.phpt]
gzcompress()/gzuncompress() [ext/zlib/tests/002.phpt]
gzencode()/base64_encode() [ext/zlib/tests/003.phpt]
=====================================================================


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-08-13 00:17 UTC] tony2001@php.net
Not enough information was provided for us to be able
to handle this bug. Please re-read the instructions at
http://bugs.php.net/how-to-report.php

If you can provide more information, feel free to add it
to this bug and change the status back to "Open".

Thank you for your interest in PHP.



 [2005-08-20 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".
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Jan 15 15:01:31 2025 UTC