ID:               33327
 User updated by:  pillepop2003 at yahoo dot de
 Reported By:      pillepop2003 at yahoo dot de
-Status:           Bogus
+Status:           Open
 Bug Type:         GD related
 Operating System: Linux
 PHP Version:      4.3.10
 New Comment:

I did say it works on my win-box, but that does not apply for the linux
version, as i caanot test it there. furthermore, i don't see any
relevant changelog entry from 4.3.10 to 4.3.11 that could have fixed
this problem.
it's up to you to decide whether to close this bug or not, but you
should make sure, this problem does not apply to linus 4.3.11


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

[2005-06-13 23:40:28] [EMAIL PROTECTED]

Please don't report bugs to old PHP versions if you've already even
checked that it WORKS with new version!!!!


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

[2005-06-13 23:37:24] pillepop2003 at yahoo dot de

I'm on a managed server, so I'm afraid I cannot install a snapshot. Did
you solve the problem in the current cvs?
btw: it perfectly works on my win32 / php 4.3.11 box.

IMHO the problem is caused by imagecreatefromstring() not being able to
deal with the file_get_contents() string.

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

[2005-06-13 22:44:00] [EMAIL PROTECTED]

Please try using this CVS snapshot:

  http://snaps.php.net/php4-STABLE-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-STABLE-latest.zip



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

[2005-06-13 22:19:13] pillepop2003 at yahoo dot de

It also doesnt work if i leave out the decode/encode:

$data = file_get_contents('test.jpg');
$im = imagecreatefromjpeg($data);

...terminates after imagecreatefromjpeg, silently.

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

[2005-06-13 21:25:00] pillepop2003 at yahoo dot de

Description:
------------
I am using PHP on Apache/1.3.29 (Unix).

The script behaves differently, depeding on PHP running as cgi or as
apache-module, in the following way:

- load jpeg into string
- save base64_encode(string) with file_put_contents() as dummy.txt
- load dummy.txt into string with file_get_contents()
- decode string with base64_decode()
- process loaded string with imagecreatefromstring()

The Script behaves fine when using php as cgi.
The script stops without any warning or response when using php as
apache-module after imagecreatefromstring().

Everything works fine without base64-encoding/decoding.

(I'm using file_put_contents from Pear::compat)
GD Version: 2.0 or higher

Reproduce code:
---------------
$data = file_get_contents('test.jpg');

file_put_contents('dummy.txt', base64_encode($data));
$data = base64_decode(file_get_contents('dummy.txt'));

$im = imagecreatefromstring($data);

echo 'helloworld';

Expected result:
----------------
output of "helloworld" with either cgi or apache-module

Actual result:
--------------
cgi-version: output 'helloworld'
apache-module: script terminates silenty after imagecreatefromstring()


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


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

Reply via email to