cvs: php4 /ext/mbstring mbstring.c
| From: | Marcus B�rger | Date: | Thu, 11 Apr 2002 22:52:43 +0000 |
| Subject: | cvs: php4 /ext/mbstring mbstring.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-11068@lists.php.net to get a copy of this message | ||
helly Thu Apr 11 18:52:43 2002 EDT
Modified files:
/php4/ext/mbstring mbstring.c
Log:
interpret empty to_encoding as encoding not set what results in current_internal_encoding
Index: php4/ext/mbstring/mbstring.c
diff -u php4/ext/mbstring/mbstring.c:1.58 php4/ext/mbstring/mbstring.c:1.59
--- php4/ext/mbstring/mbstring.c:1.58 Thu Apr 11 18:27:00 2002
+++ php4/ext/mbstring/mbstring.c Thu Apr 11 18:52:43 2002
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: mbstring.c,v 1.58 2002/04/11 22:27:00 hirokawa Exp $ */
+/* $Id: mbstring.c,v 1.59 2002/04/11 22:52:43 helly Exp $ */
/*
* PHP4 Multibyte String module "mbstring" (currently only for Japanese)
@@ -2070,7 +2070,7 @@
return NULL;
}
/* new encoding */
- if (_to_encoding) {
+ if (_to_encoding && strlen(_to_encoding)) {
to_encoding = mbfl_name2no_encoding(_to_encoding);
if (to_encoding == mbfl_no_encoding_invalid) {
php_error(E_WARNING, "%s() unknown encoding \"%s\"",