#33080 [Asn->Csd]: Bug 31465 recurring on 5.0.4
| From: | iliaa@php.net | Date: | Fri, 27 May 2005 02:03:34 +0000 |
| Subject: | #33080 [Asn->Csd]: Bug 31465 recurring on 5.0.4 | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-79583@lists.php.net to get a copy of this message | ||
ID: 33080
Updated by: iliaa@php.net
Reported By: marc at durdin dot net
-Status: Assigned
+Status: Closed
Bug Type: Strings related
Operating System: *
PHP Version: 5.0.4
Assigned To: iliaa
New Comment:
This bug has been fixed in CVS.
Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
Thank you for the report, and for helping us make PHP better.
Previous Comments:
------------------------------------------------------------------------
[2005-05-26 00:59:24] sniper@php.net
Works fine with HEAD, PHP_5_0 buggy..Ilia, you claimed to have fixed
this?
------------------------------------------------------------------------
[2005-05-25 12:54:58] marc at durdin dot net
Managed to get a script that will do it every time (seems that it
raises a E_WARNING). Again, doesn't generate the warning on 5.0.2, does
on 5.0.4.
<?php
set_error_handler("err_handler");
unpack("H*hex", 'abc');
function err_handler($errno, $errstr, $errfile, $errline, $vars)
{
echo $errno . ": " . $errstr;
}
?>
------------------------------------------------------------------------
[2005-05-20 16:27:57] tony2001@php.net
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves.
A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external
resources such as databases, etc.
If possible, make the script source available online and provide
an URL to it here. Try to avoid embedding huge scripts into the report.
------------------------------------------------------------------------
[2005-05-20 15:07:06] marc at durdin dot net
Description:
------------
Bug 31465 has been marked as fixed in 5.0.4 - however, I just upgraded
to 5.0.4 and started experiencing it on my system - using it to upload
files as follows:
I am using the stock precompiled download from php.net.
Basic PHP information:
PHP Version => 5.0.4
System => Windows NT 5.2 build 3790
Build Date => Mar 31 2005 02:44:34
Configure Command => cscript /nologo configure.js
"--enable-snapshot-build" "--with-gd=shared"
Server API => Command Line Interface
Virtual Directory Support => enabled
Configuration File (php.ini) Path => [obscured]
PHP API => 20031224
PHP Extension => 20041030
Zend Extension => 220040412
Debug Build => no
Thread Safety => enabled
IPv6 Support => enabled
Registered PHP Streams => php, file, http, ftp, compress.zlib
Registered Stream Socket Transports => tcp, udp
Marc Durdin
Reproduce code:
---------------
$datastring = file_get_contents($Filename);
$data = unpack("H*hex", $datastring);
$FileID = mssql_db_call_to_store_file($OriginalFileName,
'0x'.$data['hex']);
Expected result:
----------------
(no output expected)
Actual result:
--------------
Warning: unpack() function.unpack: Type H: outside of string
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=33080&edit=1