ID:               36720
 Updated by:       [EMAIL PROTECTED]
 Reported By:      astur103 at hotmail dot com
-Status:           Open
+Status:           Feedback
 Bug Type:         Unknown/Other Function
 Operating System: Windows XP Pro SP2
 PHP Version:      5.1.2
 New Comment:

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.




Previous Comments:
------------------------------------------------------------------------

[2006-03-13 15:41:45] astur103 at hotmail dot com

Description:
------------
Sometimes, above all if memory is clean or the function is not loaded
in memory and has to do it, chunk_split cut a base64 string wrongly.

Later, works fine.

Reproduce code:
---------------
This is the used function:

function compress_gz($string, $level = "1") {
        $final_string = "";
        IF(!empty($string)) {
                $final_string = chunk_split(base64_encode(gzcompress($string,
$level)));
        }
        return $final_string;
        unset($string);
        unset($final_string);
}


Expected result:
----------------
I guess that something like this ...

---- LAST 3 LINES OF STRING ---

0r5uCiYhgApgyg3dCkwmwrauUwVphDguNk2YXJFHqWtjYBAbJjL9iS4X14tgmvRNyD6ef+L3Ve3y
5eLawo1+GJjEDVylt2st73hav2fuh90XV7iJbHVZexbnfz9M2d8Yszv8AKlPYUQ==

---- END ----


Actual result:
--------------
---- LAST 3 LINES OF STRING ---

0r5uCiYhgApgyg3dCkwmwrauUwVphDguNk2YXJFHqWtjYBAbJjL9iS4X14tgmvRNyD6ef+L3Ve3y
5eLawo1+GJjEDVylt2st73hav2fuh90XV7iJbHVZexbnfz9M2d8=
Yszv8AKlPYUQ==

---- END ----



------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=36720&edit=1

Reply via email to