php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #49575 iconv function fails if you try to convert one character set into the same set
Submitted: 2009-09-17 01:14 UTC Modified: 2009-09-25 01:00 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:1 (100.0%)
From: me at mikearsenault dot com Assigned:
Status: No Feedback Package: ICONV related
PHP Version: 5.2SVN-2009-09-17 (SVN) OS: Linux
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: me at mikearsenault dot com
New email:
PHP Version: OS:

 

 [2009-09-17 01:14 UTC] me at mikearsenault dot com
Description:
------------
If you try to convert one character set into the same character set using this function, it causes a 500 internal server error that shows up in the logs as:

[error] [client XXX.XXX.XXX.XXX] Premature end of script headers: myscript.php

Reproduce code:
---------------
$charset = "ISO-8859-1";

try {
  $i= iconv($charset, "ISO-8859-1", "123321ksdjvskjdfksdfbasbdaSDjhdb");
  echo $i;
  } 
catch (Exception $e) {
echo 'Caught exception: ',  $e->getMessage(), "\n";	
}


Expected result:
----------------
123321ksdjvskjdfksdfbasbdaSDjhdb

Actual result:
--------------
500 Internal Server Error

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-09-17 15:34 UTC] jani@php.net
Please try using this snapshot:

  http://snaps.php.net/php5.2-latest.tar.gz
 
For Windows:

  http://windows.php.net/snapshots/

works fine for me.
 [2009-09-25 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-2024 The PHP Group
All rights reserved.
Last updated: Fri Dec 27 02:01:29 2024 UTC