#50451 [Csd->Asn]: http wrapper breaks on 2048 char long headers

2009-12-13 Thread jani
 ID:   50451
 Updated by:   j...@php.net
 Reported By:  sjo...@php.net
-Status:   Closed
+Status:   Assigned
 Bug Type: Streams related
 Operating System: *
 PHP Version:  5.*, 6
 Assigned To:  iliaa
 New Comment:

Not merged yet to PHP_5_2.


Previous Comments:


[2009-12-13 15:44:23] s...@php.net

Automatic comment from SVN on behalf of iliaa
Revision: http://svn.php.net/viewvc/?view=revision&revision=292079
Log: Fixed bug #50451 (http wrapper breaks on 2048 char long headers)

# Improvement on the fix for bug #49851



[2009-12-11 13:16:01] sjo...@php.net

Description:

If a HTTP response contains an header of exactly 2048 characters, the
remaining headers are not parsed and are returned in the output.

See also bug #49851.

 

Reproduce code:
---
http://localhost/a.php');
?>

a.php:
http://www.google.nl/');
echo "Foo";
?>

Expected result:

The homepage of google.nl.

Actual result:
--
Location: http://www.google.nl/
Content-Length: 3
Connection: close
Content-Type: text/html

Foo





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



#49851 [Csd->Asn]: http wrapper breaks on 1024 char long headers

2009-12-13 Thread jani
 ID:   49851
 Updated by:   j...@php.net
 Reported By:  sjoerd-php at linuxonly dot nl
-Status:   Closed
+Status:   Assigned
 Bug Type: Streams related
 Operating System: *
 PHP Version:  5.*, 6
-Assigned To:  
+Assigned To:  iliaa
 New Comment:

Not merged yet to PHP_5_2. 


Previous Comments:


[2009-12-13 15:44:23] s...@php.net

Automatic comment from SVN on behalf of iliaa
Revision: http://svn.php.net/viewvc/?view=revision&revision=292079
Log: Fixed bug #50451 (http wrapper breaks on 2048 char long headers)

# Improvement on the fix for bug #49851



[2009-12-11 13:17:10] sjo...@php.net

This one is fixed. Filed bug #50451 "http wrapper breaks on 2048 char
long headers".



[2009-12-10 03:23:13] il...@php.net

This bug has been fixed in SVN.

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.





[2009-12-10 03:23:05] s...@php.net

Automatic comment from SVN on behalf of iliaa
Revision: http://svn.php.net/viewvc/?view=revision&revision=291938
Log: Fixed bug #49851 (http wrapper breaks on 1024 char long headers).



[2009-12-02 18:46:39] j...@php.net

So it's a bug in streams code (http) and not server side. Your summary
for this bug report sucks and the category was wrong. And I should read
all comments. :) 



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/49851

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



#50469 [Opn->Csd]: typo in error string

2009-12-13 Thread pierrick
 ID:  50469
 Updated by:  pierr...@php.net
 Reported By: atomo64 at gmail dot com
-Status:  Open
+Status:  Closed
 Bug Type:GD related
 PHP Version: 5.2.11
 New Comment:

This bug has been fixed in SVN.

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:


[2009-12-14 04:09:19] s...@php.net

Automatic comment from SVN on behalf of pierrick
Revision: http://svn.php.net/viewvc/?view=revision&revision=292109
Log: - Fixed bug #50469 (Fixed typo in imagepsencodefont error string).



[2009-12-13 22:19:17] atomo64 at gmail dot com

Description:

There's a typo in one of the error messages:
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Couldn't reencode font");

s/reencode/re-encode/






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



#50458 [Opn->Csd]: PDO::FETCH_FUNC fails with Closures

2009-12-13 Thread pierrick
 ID:   50458
 Updated by:   pierr...@php.net
 Reported By:  m dot kurzyna at crystalpoint dot pl
-Status:   Open
+Status:   Closed
 Bug Type: PDO related
 Operating System: Linux
 PHP Version:  5.3.1
 New Comment:

This bug has been fixed in SVN.

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:


[2009-12-14 03:44:33] s...@php.net

Automatic comment from SVN on behalf of pierrick
Revision: http://svn.php.net/viewvc/?view=revision&revision=292107
Log: - Fixed bug #50458 (PDO::FETCH_FUNC fails with Closures)



[2009-12-12 13:01:34] m dot kurzyna at crystalpoint dot pl

Description:

PDOStatement::fetchAll(PDO::FETCH_FUNC,function() {}) fails not being
able to recognize Closure as valid callback.

Reproduce code:
---
exec('CREATE TABLE `a` ( `id` INTEGER )');

 $st = $db->query('SELECT * FROM `a`');
 $st->fetchAll(PDO::FETCH_FUNC,function() {});
?>


Expected result:

No error

Actual result:
--
Warning: PDOStatement::fetchAll() [pdostatement.fetchall]:
SQLSTATE[HY000]: General error: user-supplied function must be a valid
callback in ... on line 6





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



#48811 [Com]: Directives in PATH section do not get applied to subdirectories

2009-12-13 Thread ct at swin dot edu dot au
 ID:   48811
 Comment by:   ct at swin dot edu dot au
 Reported By:  ct at swin dot edu dot au
 Status:   No Feedback
 Bug Type: PHP options/info functions
 Operating System: Red Hat Enterprise Linux 5
 PHP Version:  5.3.0
 New Comment:

--- php_ini.c-orig  2009-07-06 16:04:43.0 +1000
+++ php_ini.c   2009-07-06 15:58:32.0 +1000
 -795,7 +795,7 @@
while ((ptr = strchr(ptr, DEFAULT_SLASH)) != NULL) {
*ptr = 0;
/* Search for source array matching the path
from configuration_hash */
-   if (zend_hash_find(&configuration_hash, path,
path_len, (void **) &tmp) == SUCCESS) {
+   if (zend_hash_find(&configuration_hash, path,
strlen(path) + 1, (void **) &tmp) == SUCCESS) {
   
php_ini_activate_config(Z_ARRVAL_P(tmp), PHP_INI_SYSTEM,
PHP_INI_STAGE_ACTIVATE TSRMLS_CC);
}
*ptr = '/';


Previous Comments:


[2009-12-08 01:00:01] 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".



[2009-12-02 00:06:09] ct at swin dot edu dot au

That pastebin.com entry was set to expire after 1 month.

I've uploaded it again

http://pastebin.com/f45a38211



[2009-11-30 19:38:01] j...@php.net

There is no patch there. If it's simple and not very long, add it here
as comment instead. 



[2009-07-06 06:26:40] ct at swin dot edu dot au

Description:

A php.ini file with directives in a PATH section do not get applied for
subdirectories in the defined path.

For example

[PATH=/vhost/www.example.com/dir1]

will work for scripts in /vhost/www.example.com/dir1, but not
/vhost/www.example.com/dir1/dir2.

I have fixed this on my system using the following patch
http://pastebin.com/m7e79576f











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



#50469 [NEW]: typo in error string

2009-12-13 Thread atomo64 at gmail dot com
From: atomo64 at gmail dot com
Operating system: 
PHP version:  5.2.11
PHP Bug Type: GD related
Bug description:  typo in error string

Description:

There's a typo in one of the error messages:
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Couldn't reencode font");

s/reencode/re-encode/


-- 
Edit bug report at http://bugs.php.net/?id=50469&edit=1
-- 
Try a snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=50469&r=trysnapshot52
Try a snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=50469&r=trysnapshot53
Try a snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=50469&r=trysnapshot60
Fixed in SVN:
http://bugs.php.net/fix.php?id=50469&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=50469&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=50469&r=alreadyfixed
Need backtrace:  
http://bugs.php.net/fix.php?id=50469&r=needtrace
Need Reproduce Script:   
http://bugs.php.net/fix.php?id=50469&r=needscript
Try newer version:   
http://bugs.php.net/fix.php?id=50469&r=oldversion
Not developer issue: 
http://bugs.php.net/fix.php?id=50469&r=support
Expected behavior:   
http://bugs.php.net/fix.php?id=50469&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=50469&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=50469&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=50469&r=globals
PHP 4 support discontinued:  http://bugs.php.net/fix.php?id=50469&r=php4
Daylight Savings:http://bugs.php.net/fix.php?id=50469&r=dst
IIS Stability:   
http://bugs.php.net/fix.php?id=50469&r=isapi
Install GNU Sed: 
http://bugs.php.net/fix.php?id=50469&r=gnused
Floating point limitations:  
http://bugs.php.net/fix.php?id=50469&r=float
No Zend Extensions:  
http://bugs.php.net/fix.php?id=50469&r=nozend
MySQL Configuration Error:   
http://bugs.php.net/fix.php?id=50469&r=mysqlcfg



#49399 [Opn->Bgs]: mb_ereg_replace() '\b' fails with mbstrings

2009-12-13 Thread jani
 ID:   49399
 Updated by:   j...@php.net
 Reported By:  manfred at mabuweb dot com
-Status:   Open
+Status:   Bogus
 Bug Type: mbstring related
 Operating System: linux
 PHP Version:  5.2.10
 Assigned To:  moriyoshi
 New Comment:

Exactly..


Previous Comments:


[2009-12-13 21:49:13] manfred at mabuweb dot com

Good question!

php -i |grep mbstring
mbstring.detect_order => no value => no value
mbstring.encoding_translation => Off => Off
mbstring.func_overload => 0 => 0
mbstring.http_input => pass => pass
mbstring.http_output => pass => pass
mbstring.internal_encoding => ISO-8859-1 => no value
mbstring.language => neutral => neutral
mbstring.substitute_character => no value => no value

If I change to UTF-8 everything seems to work as expected:
ini_set('mbstring.internal_encoding', 'UTF-8');



[2009-12-13 20:34:09] j...@php.net

Exactly what encodings are you using? (check phpinfo() for mbstring.*)

# php -i |grep mbstring\\.
mbstring.detect_order => no value => no value
mbstring.encoding_translation => Off => Off
mbstring.func_overload => 7 => 7
mbstring.http_input => pass => pass
mbstring.http_output => pass => pass
mbstring.internal_encoding => UTF-8 => UTF-8
mbstring.language => neutral => neutral
mbstring.strict_detection => Off => Off
mbstring.substitute_character => no value => no value




[2009-12-13 20:32:38] j...@php.net

I can't:

# php -v
PHP 5.2.12RC2-dev (cli) (built: Nov 22 2009 02:36:43)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies
# php t.php
Días
Días





[2009-12-13 20:32:12] manfred at mabuweb dot com

I've no 5.3 version to try, but I just tried in 5.2.11 and can
reproduce the error.



[2009-12-13 19:32:46] fel...@php.net

I can reproduce it only in 5.2.



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/49399

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



#49399 [Fbk->Opn]: mb_ereg_replace() '\b' fails with mbstrings

2009-12-13 Thread manfred at mabuweb dot com
 ID:   49399
 User updated by:  manfred at mabuweb dot com
 Reported By:  manfred at mabuweb dot com
-Status:   Feedback
+Status:   Open
 Bug Type: mbstring related
 Operating System: linux
 PHP Version:  5.2.10
 Assigned To:  moriyoshi
 New Comment:

Good question!

php -i |grep mbstring
mbstring.detect_order => no value => no value
mbstring.encoding_translation => Off => Off
mbstring.func_overload => 0 => 0
mbstring.http_input => pass => pass
mbstring.http_output => pass => pass
mbstring.internal_encoding => ISO-8859-1 => no value
mbstring.language => neutral => neutral
mbstring.substitute_character => no value => no value

If I change to UTF-8 everything seems to work as expected:
ini_set('mbstring.internal_encoding', 'UTF-8');


Previous Comments:


[2009-12-13 20:34:09] j...@php.net

Exactly what encodings are you using? (check phpinfo() for mbstring.*)

# php -i |grep mbstring\\.
mbstring.detect_order => no value => no value
mbstring.encoding_translation => Off => Off
mbstring.func_overload => 7 => 7
mbstring.http_input => pass => pass
mbstring.http_output => pass => pass
mbstring.internal_encoding => UTF-8 => UTF-8
mbstring.language => neutral => neutral
mbstring.strict_detection => Off => Off
mbstring.substitute_character => no value => no value




[2009-12-13 20:32:38] j...@php.net

I can't:

# php -v
PHP 5.2.12RC2-dev (cli) (built: Nov 22 2009 02:36:43)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies
# php t.php
Días
Días





[2009-12-13 20:32:12] manfred at mabuweb dot com

I've no 5.3 version to try, but I just tried in 5.2.11 and can
reproduce the error.



[2009-12-13 19:32:46] fel...@php.net

I can reproduce it only in 5.2.



[2009-08-28 13:17:16] manfred at mabuweb dot com

Description:

mb_ereg_replace() and mb_eregi_replace() misinterpretate MBchars as
word end.

Reproduce code:
---
  $pattern = '\bas\b';
  $string = 'Días';
  echo $string.'';
  echo mb_ereg_replace($pattern,  '', $string);


Expected result:

Días
Días


Actual result:
--
Días
Dí






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



#49399 [Asn->Fbk]: mb_ereg_replace() '\b' fails with mbstrings

2009-12-13 Thread jani
 ID:   49399
 Updated by:   j...@php.net
 Reported By:  manfred at mabuweb dot com
-Status:   Assigned
+Status:   Feedback
 Bug Type: mbstring related
 Operating System: linux
 PHP Version:  5.2.10
 Assigned To:  moriyoshi
 New Comment:

Exactly what encodings are you using? (check phpinfo() for mbstring.*)

# php -i |grep mbstring\\.
mbstring.detect_order => no value => no value
mbstring.encoding_translation => Off => Off
mbstring.func_overload => 7 => 7
mbstring.http_input => pass => pass
mbstring.http_output => pass => pass
mbstring.internal_encoding => UTF-8 => UTF-8
mbstring.language => neutral => neutral
mbstring.strict_detection => Off => Off
mbstring.substitute_character => no value => no value



Previous Comments:


[2009-12-13 20:32:38] j...@php.net

I can't:

# php -v
PHP 5.2.12RC2-dev (cli) (built: Nov 22 2009 02:36:43)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies
# php t.php
Días
Días





[2009-12-13 20:32:12] manfred at mabuweb dot com

I've no 5.3 version to try, but I just tried in 5.2.11 and can
reproduce the error.



[2009-12-13 19:32:46] fel...@php.net

I can reproduce it only in 5.2.



[2009-08-28 13:17:16] manfred at mabuweb dot com

Description:

mb_ereg_replace() and mb_eregi_replace() misinterpretate MBchars as
word end.

Reproduce code:
---
  $pattern = '\bas\b';
  $string = 'Días';
  echo $string.'';
  echo mb_ereg_replace($pattern,  '', $string);


Expected result:

Días
Días


Actual result:
--
Días
Dí






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



#49399 [Asn]: mb_ereg_replace() '\b' fails with mbstrings

2009-12-13 Thread jani
 ID:   49399
 Updated by:   j...@php.net
 Reported By:  manfred at mabuweb dot com
 Status:   Assigned
 Bug Type: mbstring related
 Operating System: linux
-PHP Version:  5.2.11
+PHP Version:  5.2.10
 Assigned To:  moriyoshi
 New Comment:

I can't:

# php -v
PHP 5.2.12RC2-dev (cli) (built: Nov 22 2009 02:36:43)
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2009 Zend Technologies
# php t.php
Días
Días




Previous Comments:


[2009-12-13 20:32:12] manfred at mabuweb dot com

I've no 5.3 version to try, but I just tried in 5.2.11 and can
reproduce the error.



[2009-12-13 19:32:46] fel...@php.net

I can reproduce it only in 5.2.



[2009-08-28 13:17:16] manfred at mabuweb dot com

Description:

mb_ereg_replace() and mb_eregi_replace() misinterpretate MBchars as
word end.

Reproduce code:
---
  $pattern = '\bas\b';
  $string = 'Días';
  echo $string.'';
  echo mb_ereg_replace($pattern,  '', $string);


Expected result:

Días
Días


Actual result:
--
Días
Dí






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



#49399 [Asn]: mb_ereg_replace() '\b' fails with mbstrings

2009-12-13 Thread manfred at mabuweb dot com
 ID:   49399
 User updated by:  manfred at mabuweb dot com
 Reported By:  manfred at mabuweb dot com
 Status:   Assigned
 Bug Type: mbstring related
 Operating System: linux
-PHP Version:  5.2.10
+PHP Version:  5.2.11
 Assigned To:  moriyoshi
 New Comment:

I've no 5.3 version to try, but I just tried in 5.2.11 and can
reproduce the error.


Previous Comments:


[2009-12-13 19:32:46] fel...@php.net

I can reproduce it only in 5.2.



[2009-08-28 13:17:16] manfred at mabuweb dot com

Description:

mb_ereg_replace() and mb_eregi_replace() misinterpretate MBchars as
word end.

Reproduce code:
---
  $pattern = '\bas\b';
  $string = 'Días';
  echo $string.'';
  echo mb_ereg_replace($pattern,  '', $string);


Expected result:

Días
Días


Actual result:
--
Días
Dí






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



#50451 [Asn->Csd]: http wrapper breaks on 2048 char long headers

2009-12-13 Thread jani
 ID:   50451
 Updated by:   j...@php.net
 Reported By:  sjo...@php.net
-Status:   Assigned
+Status:   Closed
 Bug Type: Streams related
 Operating System: *
 PHP Version:  5.*, 6
 Assigned To:  iliaa


Previous Comments:


[2009-12-13 15:44:23] s...@php.net

Automatic comment from SVN on behalf of iliaa
Revision: http://svn.php.net/viewvc/?view=revision&revision=292079
Log: Fixed bug #50451 (http wrapper breaks on 2048 char long headers)

# Improvement on the fix for bug #49851



[2009-12-11 13:16:01] sjo...@php.net

Description:

If a HTTP response contains an header of exactly 2048 characters, the
remaining headers are not parsed and are returned in the output.

See also bug #49851.

 

Reproduce code:
---
http://localhost/a.php');
?>

a.php:
http://www.google.nl/');
echo "Foo";
?>

Expected result:

The homepage of google.nl.

Actual result:
--
Location: http://www.google.nl/
Content-Length: 3
Connection: close
Content-Type: text/html

Foo





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



#50467 [Opn->Bgs]: Displaying multiple images, BLOB data, from a MySQL database

2009-12-13 Thread jani
 ID:   50467
 Updated by:   j...@php.net
 Reported By:  businessitconsulting at yahoo dot com
-Status:   Open
+Status:   Bogus
 Bug Type: MySQL related
 Operating System: Linux
 PHP Version:  5.3.1
 New Comment:

Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.




Previous Comments:


[2009-12-13 19:59:43] businessitconsulting at yahoo dot com

Description:

Need to display multiple images stored as BLOB data types in a MySQL
table. Using a while loop, other fields in the same table with text data
type, displays in a browser showing all rows when the BLOB field is not
included.

The BLOB data (the images), often are displayed as binary data but
needs to show as actual images.

Apparently there is an issue with PHP with displaying the binary data
stored in a variable directly as an image when echoing or printing the
variable with BLOB data using echo $TheBlobData; or print
$TheBlobData;.

In some instances, the query executes, retrieves all rows but only
displays an image, instead of all the images per row.

Storing the images in directories has security issues, other risk and
the BLOB data needs to be stored and pulled directly from the database.



Field Name, DataType
-
ID, int
Picture, BLOB
Type, VARCHAR

For example this prints the ID of each row:
while ($rows = mysql_fetch_row($result))
{
echo $rows->ID;
}
and this prints the image Type stored in a field of each row

while ($rows = mysql_fetch_row($result))
{
echo $rows->Type;
}

but this prints each row of the images as binary data but needs to
print actual images:

while ($rows = mysql_fetch_row($result))
{
echo $rows->Picture;
}

When inserting the header() function to describe the image data type,
it only prints an image using the same while loop, in some cases it
simply shows a blank page and echos the address of the page:

while ($rows = mysql_fetch_row($result))
{
header ();
echo $rows->Picture;
}

This requires printing the multiple BLOB data directly as images to a
page for each row in a table and not just an image on the page. For
users of Postgres SQL, is this also an issue and are they open source
databases where BLOB data types can be displayed directly as images by
echoing or printing the BLOB data variable?






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



#50467 [NEW]: Displaying multiple images, BLOB data, from a MySQL database

2009-12-13 Thread businessitconsulting at yahoo dot com
From: businessitconsulting at yahoo dot com
Operating system: Linux
PHP version:  5.3.1
PHP Bug Type: Variables related
Bug description:  Displaying multiple images, BLOB data, from a MySQL database

Description:

Need to display multiple images stored as BLOB data types in a MySQL
table. Using a while loop, other fields in the same table with text data
type, displays in a browser showing all rows when the BLOB field is not
included.

The BLOB data (the images), often are displayed as binary data but needs
to show as actual images.

Apparently there is an issue with PHP with displaying the binary data
stored in a variable directly as an image when echoing or printing the
variable with BLOB data using echo $TheBlobData; or print $TheBlobData;.

In some instances, the query executes, retrieves all rows but only
displays an image, instead of all the images per row.

Storing the images in directories has security issues, other risk and the
BLOB data needs to be stored and pulled directly from the database.



Field Name, DataType
-
ID, int
Picture, BLOB
Type, VARCHAR

For example this prints the ID of each row:
while ($rows = mysql_fetch_row($result))
{
echo $rows->ID;
}
and this prints the image Type stored in a field of each row

while ($rows = mysql_fetch_row($result))
{
echo $rows->Type;
}

but this prints each row of the images as binary data but needs to print
actual images:

while ($rows = mysql_fetch_row($result))
{
echo $rows->Picture;
}

When inserting the header() function to describe the image data type, it
only prints an image using the same while loop, in some cases it simply
shows a blank page and echos the address of the page:

while ($rows = mysql_fetch_row($result))
{
header ();
echo $rows->Picture;
}

This requires printing the multiple BLOB data directly as images to a page
for each row in a table and not just an image on the page. For users of
Postgres SQL, is this also an issue and are they open source databases
where BLOB data types can be displayed directly as images by echoing or
printing the BLOB data variable?


-- 
Edit bug report at http://bugs.php.net/?id=50467&edit=1
-- 
Try a snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=50467&r=trysnapshot52
Try a snapshot (PHP 5.3):
http://bugs.php.net/fix.php?id=50467&r=trysnapshot53
Try a snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=50467&r=trysnapshot60
Fixed in SVN:
http://bugs.php.net/fix.php?id=50467&r=fixed
Fixed in SVN and need be documented: 
http://bugs.php.net/fix.php?id=50467&r=needdocs
Fixed in release:
http://bugs.php.net/fix.php?id=50467&r=alreadyfixed
Need backtrace:  
http://bugs.php.net/fix.php?id=50467&r=needtrace
Need Reproduce Script:   
http://bugs.php.net/fix.php?id=50467&r=needscript
Try newer version:   
http://bugs.php.net/fix.php?id=50467&r=oldversion
Not developer issue: 
http://bugs.php.net/fix.php?id=50467&r=support
Expected behavior:   
http://bugs.php.net/fix.php?id=50467&r=notwrong
Not enough info: 
http://bugs.php.net/fix.php?id=50467&r=notenoughinfo
Submitted twice: 
http://bugs.php.net/fix.php?id=50467&r=submittedtwice
register_globals:
http://bugs.php.net/fix.php?id=50467&r=globals
PHP 4 support discontinued:  http://bugs.php.net/fix.php?id=50467&r=php4
Daylight Savings:http://bugs.php.net/fix.php?id=50467&r=dst
IIS Stability:   
http://bugs.php.net/fix.php?id=50467&r=isapi
Install GNU Sed: 
http://bugs.php.net/fix.php?id=50467&r=gnused
Floating point limitations:  
http://bugs.php.net/fix.php?id=50467&r=float
No Zend Extensions:  
http://bugs.php.net/fix.php?id=50467&r=nozend
MySQL Configuration Error:   
http://bugs.php.net/fix.php?id=50467&r=mysqlcfg



#49174 [Fbk->Csd]: crash on queryString set

2009-12-13 Thread felipe
 ID:   49174
 Updated by:   fel...@php.net
 Reported By:  joelrengmyr at gmail dot com
-Status:   Feedback
+Status:   Closed
 Bug Type: PDO related
-Operating System: win
+Operating System: *
-PHP Version:  5.3.0
+PHP Version:  5.2, 5.3, 6
-Assigned To:  
+Assigned To:  felipe
 New Comment:

This bug has been fixed in SVN.

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:


[2009-12-13 19:53:45] s...@php.net

Automatic comment from SVN on behalf of felipe
Revision: http://svn.php.net/viewvc/?view=revision&revision=292083
Log: - Fixed bug #49174 (crash on queryString set)



[2009-12-13 19:41:07] fel...@php.net

Please try using this snapshot:

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

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





[2009-08-14 01:00:01] 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".



[2009-08-06 01:16:32] scott...@php.net

Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.

And a reproduce script, ideally a self contained script that's no more
than 20 lines of code.



[2009-08-06 00:43:11] joelrengmyr at gmail dot com

Description:

Extending PDOStatement and trying to set queryString property will
crash 
server.






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



#50462 [Fbk->Bgs]: mysqli_more_results does not play well with mysqli_multi_query()

2009-12-13 Thread johannes
 ID:   50462
 Updated by:   johan...@php.net
 Reported By:  pcdinh at gmail dot com
-Status:   Feedback
+Status:   Bogus
 Bug Type: MySQLi related
 Operating System: Windows XP
 PHP Version:  5.3.1
 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

Your code is wrong. There will always be one result set which will be
active. mysqli_more_results() will tell you whether there is yet another
result set but you're on the last (and only) result set so there's no
other.


Previous Comments:


[2009-12-13 05:44:25] pcdinh at gmail dot com

The problem is mysqli_more_results($conn) needs to be called first to 
check if there is at least one result returned.

The code below is valid if I make a single query that returns multiple

result set 

mysqli_multi_query($conn, $query);

while (mysqli_more_results($conn))
{
mysqli_next_result($query);

/* store first result set */
if ($result = mysqli_store_result($conn)) {
 
}
}

When I use mysqli_multi_query() I may not know how many queries are 
there in $query. Therefore I would like to use mysqli_more_results() 
to check if I can loop through the result sets. It is the same as in 
array iteration

Single element: array(1)=> using for: yes
2 elements: array(1, 2) => using for: yes

But when it comes to mysqli_multi_query()

Single element: array(1)=> using while: no
2 elements: array(1, 2) => using while: yes

Because mysqli_multi_query() deals with multiple result sets, it is 
expected to have unified iteration interface for both single result 
set and multiple result sets.

Also the behavior is defined in PHP Manual that 

"Indicates if one or more result sets are available from a previous 
call to mysqli_multi_query()."

It means that mysqli_more_results($conn) must return true in my case

mysqli_multi_query($conn, $query);

while (mysqli_more_results($conn))
{

}

because in fact I do not know if there is any result returned at all 
after calling mysqli_multi_query(). So while 
(mysqli_more_results($conn)) is a good way to do if any.



[2009-12-12 22:19:44] j...@php.net

Exactly what is confusing here? Your first script does single query ->
there are no more results than the one. So why would
mysqli_more_results() return true since there are no more results..?



[2009-12-12 21:54:29] pcdinh at gmail dot com

Hi,

I found that mysqli_more_results() return true when there is more than

1 query



bool(true)

However, this behavior is totally confused



[2009-12-12 21:41:44] pcdinh at gmail dot com

Description:

mysqli_more_results() will always return false after 
mysqli_multi_query() for both SELECT and non SELECT queries

Therefore I can not use the loop while (mysqli_more_results()) in 
combination with mysqli_next_result() to iterate through result sets 
produced by SELECT queries

mysqli_multi_query($conn, $query);

while (mysqli_more_results($conn))
{
mysqli_next_result($query);

/* store first result set */
if ($result = mysqli_store_result($conn)) {
 
}
}

Code example in http://php.net/manual/en/mysqli.multi-query.php is 
outdated because it causes E_STRICT in PHP 5.3.1. It requires 
mysqli_more_results() to be called before mysqli_next_result()

There is a workaround

if (mysqli_multi_query($link, $query)) {
do {
/* store first result set */
if ($result = mysqli_store_result($link)) {
while ($row = mysqli_fetch_row($result)) {
printf("%s\n", $row[0]);
}
mysqli_free_result($result);
}

// print divider => will never work
if (mysqli_more_results($link)) {
printf("-\n");
}
} while (mysqli_more_results($link) && mysqli_next_result($link));
}

but mysqli_more_results() seems to do nothing related to result sets 
here


Reproduce code:
---


Expected result:

bool(true)

Actual result:
--
bool(false)





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



#49174 [NoF->Fbk]: crash on queryString set

2009-12-13 Thread felipe
 ID:   49174
 Updated by:   fel...@php.net
 Reported By:  joelrengmyr at gmail dot com
-Status:   No Feedback
+Status:   Feedback
 Bug Type: PDO related
 Operating System: win
 PHP Version:  5.3.0
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2009-08-14 01:00:01] 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".



[2009-08-06 01:16:32] scott...@php.net

Thank you for this bug report. To properly diagnose the problem, we
need a backtrace to see what is happening behind the scenes. To
find out how to generate a backtrace, please read
http://bugs.php.net/bugs-generating-backtrace.php for *NIX and
http://bugs.php.net/bugs-generating-backtrace-win32.php for Win32

Once you have generated a backtrace, please submit it to this bug
report and change the status back to "Open". Thank you for helping
us make PHP better.

And a reproduce script, ideally a self contained script that's no more
than 20 lines of code.



[2009-08-06 00:43:11] joelrengmyr at gmail dot com

Description:

Extending PDOStatement and trying to set queryString property will
crash 
server.






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



#49399 [NoF->Asn]: mb_ereg_replace() '\b' fails with mbstrings

2009-12-13 Thread felipe
 ID:   49399
 Updated by:   fel...@php.net
 Reported By:  manfred at mabuweb dot com
-Status:   No Feedback
+Status:   Assigned
 Bug Type: mbstring related
 Operating System: linux
 PHP Version:  5.2.10
-Assigned To:  
+Assigned To:  moriyoshi
 New Comment:

I can reproduce it only in 5.2.


Previous Comments:


[2009-09-05 01:00:00] 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".



[2009-08-29 00:31:29] j...@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-08-28 13:17:16] manfred at mabuweb dot com

Description:

mb_ereg_replace() and mb_eregi_replace() misinterpretate MBchars as
word end.

Reproduce code:
---
  $pattern = '\bas\b';
  $string = 'Días';
  echo $string.'';
  echo mb_ereg_replace($pattern,  '', $string);


Expected result:

Días
Días


Actual result:
--
Días
Dí






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



#49226 [NoF->Fbk]: SoapServer failing on construction (cannot load wsdl)

2009-12-13 Thread felipe
 ID:   49226
 Updated by:   fel...@php.net
 Reported By:  richard at rjharrison dot org
-Status:   No Feedback
+Status:   Feedback
 Bug Type: SOAP related
 Operating System: linux
 PHP Version:  5.3.0
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2009-10-15 01:00:00] 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".



[2009-10-09 10:17:18] evalds at 2egames dot com

I am using latest PHP 5.3 and still having this annoying bug - 
the easy quick fix for SoapServer error is to add header like (thank
you 
"stig dot woxholt at fotoknudsen dot no" for indentifiying the
problem).

To fix this you have to add content-length in your wsdl generator
code:

header('Content-Length: '.strlen($strWsdl));
echo $restOfWsdl;



[2009-10-07 18:30:16] sjo...@php.net

See also Bug #48216 PHP Fatal error: SOAP-ERROR: Parsing WSDL: Extra
content at the end of the doc



[2009-10-07 16:28:23] petro at eps1lon dot com

That should be 5.3.1RC1.



[2009-10-07 16:25:01] petro at eps1lon dot com

I was having the same problem with SoapClient under 5.3.0.  It is
working fine under 5.3.RC1.



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/49226

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



#48216 [NoF->Fbk]: PHP Fatal error: SOAP-ERROR: Parsing WSDL: Extra content at the end of the doc

2009-12-13 Thread felipe
 ID:   48216
 Updated by:   fel...@php.net
 Reported By:  mark at everytruckjob dot com
-Status:   No Feedback
+Status:   Feedback
 Bug Type: SOAP related
 Operating System: CentOs 5.3
 PHP Version:  5.3.0RC2
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2009-12-02 16:29:03] php dot net at drsdre dot org

Had the same issue with PHP 5.3.0. Content-lenght was available in the
header, but PHP gace fatel error 'extra content at the end of the
document'.

With php-5.3-win32-VC6-x85-latest.zip the WSDL is being read without
problems.



[2009-11-23 19:04:52] ondra dot podolinsky at seznam dot cz

The same problem: win xp, php 5.3.0.
[faultstring] => SOAP-ERROR: Parsing WSDL: Couldn't load from
'http://webapi.allegro.pl/uploader.php?wsdl' : Extra content at the end
of the document [faultcode] => WSDL



[2009-11-17 10:37:17] dmitry dot dulepov at gmail dot com

Same issue on PHP 5.3 that comes with Mac OS X:

Fatal error: SOAP-ERROR: Parsing WSDL: Couldn't load from 
'http://typo3.org/wsdl/tx_ter_wsdl.php' : Extra content at the end of 
the document in /Users/user/Projects/TYPO3/typo3_src-
4.2.6/typo3/mod/tools/em/class.em_soap.php on line 115



[2009-10-30 15:04:50] nadavkav at gmail dot com

similar issue, on Debian unstable , PHP/5.3.0-3

laptop:/var/www/moodle-weekly/wspp/clients# ./mkclasses.sh
PHP Notice:  Undefined offset: 2 in /var/www/moodle-
weekly/wspp/wsdl2php.php on line 84
PHP Notice:  Undefined offset: 2 in /var/www/moodle-
weekly/wspp/wsdl2php.php on line 85
PHP Fatal error:  SOAP-ERROR: Parsing WSDL: Couldn't load from 
'http://localhost/moodle-weekly/wspp/wsdl_pp.php' : Extra content at 
the end of the document
 in /var/www/moodle-weekly/wspp/wsdl2php.php on line 88
SoapFault exception: [WSDL] SOAP-ERROR: Parsing WSDL: Couldn't load 
from 'http://localhost/moodle-weekly/wspp/wsdl_pp.php' : Extra content

at the end of the document
 in /var/www/moodle-weekly/wspp/wsdl2php.php:88
Stack trace:
#0 /var/www/moodle-weekly/wspp/wsdl2php.php(88): SoapClient-
>SoapClient('http://localhos...')
#1 {main}laptop:/var/www/moodle-weekly/wspp/clients#



[2009-10-30 15:04:23] nadavkav at gmail dot com

similar issue, on Debian unstable , PHP/5.3.0-3

laptop:/var/www/moodle-weekly/wspp/clients# ./mkclasses.sh
PHP Notice:  Undefined offset: 2 in /var/www/moodle-
weekly/wspp/wsdl2php.php on line 84
PHP Notice:  Undefined offset: 2 in /var/www/moodle-
weekly/wspp/wsdl2php.php on line 85
PHP Fatal error:  SOAP-ERROR: Parsing WSDL: Couldn't load from 
'http://localhost/moodle-weekly/wspp/wsdl_pp.php' : Extra content at 
the end of the document
 in /var/www/moodle-weekly/wspp/wsdl2php.php on line 88
SoapFault exception: [WSDL] SOAP-ERROR: Parsing WSDL: Couldn't load 
from 'http://localhost/moodle-weekly/wspp/wsdl_pp.php' : Extra content

at the end of the document
 in /var/www/moodle-weekly/wspp/wsdl2php.php:88
Stack trace:
#0 /var/www/moodle-weekly/wspp/wsdl2php.php(88): SoapClient-
>SoapClient('http://localhos...')
#1 {main}laptop:/var/www/moodle-weekly/wspp/clients#



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/48216

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



#49446 [NoF->Csd]: escapeshellarg dosn`t work on windows

2009-12-13 Thread felipe
 ID:   49446
 Updated by:   fel...@php.net
 Reported By:  heromantor at users dot sourceforge dot net
-Status:   No Feedback
+Status:   Closed
 Bug Type: CGI related
 Operating System: windows xp sp2
 PHP Version:  5.2.10


Previous Comments:


[2009-09-11 01:00:00] 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".



[2009-09-03 04:16:48] scott...@php.net

This was fixed in 5.3 with bug #43261

Though \\ within double quotes is considered a single \



[2009-09-02 23:51:40] heromantor at users dot sourceforge dot net

oh sorry, i post invalid patch.

this ok:
--- exec.c  Wed Sep  2 23:44:19 2009
+++ exec_fixed.cWed Sep  2 23:44:41 2009
@@ -343,7 +343,7 @@
  */
 PHPAPI char *php_escape_shell_arg(char *str)
 {
-int x, y = 0, l = strlen(str);
+int x, y = 0, j, l = strlen(str);
 char *cmd;
 size_t estimate = (4 * l) + 3;
 
@@ -352,6 +352,11 @@
 cmd = safe_emalloc(4, l, 3); /* worst case */
 
 #ifdef PHP_WIN32
+#   define PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES() \
+for(j = y - 1; j > 0 && cmd[j] == '\\'; --j) { \
+cmd[y++] = '\\'; \
+}
+
 cmd[y++] = '"';
 #else
 cmd[y++] = '\'';
@@ -372,10 +377,16 @@
 
 switch (str[x]) {
 #ifdef PHP_WIN32
-case '"':
-case '%':
-cmd[y++] = ' ';
-break;
+case '%':
+PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES()
+cmd[y++] = '"';
+cmd[y++] = '%';
+cmd[y++] = '"';
+break;
+case '"':
+PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES()
+cmd[y++] = '"';
+/* fall-through */
 #else
 case '\'':
 cmd[y++] = '\'';
@@ -388,6 +399,9 @@
 }
 }
 #ifdef PHP_WIN32
+PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES()
+#   undef PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES
+
 cmd[y++] = '"';
 #else
 cmd[y++] = '\'';



[2009-09-02 23:10:52] heromantor at users dot sourceforge dot net

Description:

escapeshellarg function dosn`t work properly on windows platform.
Problem in " \ and % chars handling.

this patch fix this problem
--- exec.c  Wed Sep  2 22:41:27 2009
+++ exec_fixed.cWed Sep  2 22:40:50 2009
@@ -352,6 +352,11 @@
cmd = safe_emalloc(4, l, 3); /* worst case */
 
 #ifdef PHP_WIN32
+#   define PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES() \
+for(j = y - 1; j > 0 && cmd[j] == '\\'; --j) { \
+cmd[y++] = '\\'; \
+}
+
cmd[y++] = '"';
 #else
cmd[y++] = '\'';
@@ -372,10 +377,16 @@
 
switch (str[x]) {
 #ifdef PHP_WIN32
-   case '"':
-   case '%':
-   cmd[y++] = ' ';
-   break;
+case '%':
+PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES()
+cmd[y++] = '"';
+cmd[y++] = '%';
+cmd[y++] = '"';
+break;
+case '"':
+PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES()
+cmd[y++] = '"';
+/* fall-through */
 #else
case '\'':
cmd[y++] = '\'';
@@ -388,6 +399,9 @@
}
}
 #ifdef PHP_WIN32
+PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES()
+#   undef PHP_ESCAPE_SHELL_ARG_PROCESS_TRAILING_SLASHES
+
cmd[y++] = '"';
 #else
cmd[y++] = '\'';

and some test cases
P A T H => "P A T H"
%PATH% => ""%"PATH"%""
a%PATH%b => "a"%"PATH"%"b"
%%PATH%% => ""%""%"PATH"%""%""
"PATH" => """PATH"""
"%PATH%" => %"PATH"%
\P\A\T\H => "\P\A\T\H"
\P\A\T\H\ => "\P\A\T\H\\"
\%\%\ => "\\"%"\\"%"\\"
a\\%b\\c%\\ => "a"%"b\\c"%""
"a\" => """a\\"""
a\" => "a\\"""
a\"^|^&^(^) => "a\\""^|^&^(^)"
PATH\%\ => "PATH\\"%"\\"


Reproduce code:
---
http://bugs.php.net/?id=49446&edit=1



#50192 [NoF->Fbk]: SSL Success, Failed to enable crypto

2009-12-13 Thread felipe
 ID:   50192
 Updated by:   fel...@php.net
 Reported By:  pablo at bng5 dot net
-Status:   No Feedback
+Status:   Feedback
 Bug Type: Apache2 related
 Operating System: Ubuntu 8.10/9.04
 PHP Version:  5.2.6
 New Comment:

Please try using this snapshot:

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

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

I cannot reproduce it.


Previous Comments:


[2009-11-25 01:00:01] 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".



[2009-11-17 09:27:31] j...@php.net

Please try using this snapshot:

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

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





[2009-11-16 19:00:20] pablo at bng5 dot net

Description:

Cannot open a secure socket with 'fsockopen' function.

My PHP Version is 5.2.6-3ubuntu4.2, I installed it from the Ubuntu
repositories, this is the latest PHP version I can get from there.

The same script works fine with PHP-CLI, but throws an error on Apache2
(same PHP installation).

Excuse my english.

Reproduce code:
---



Expected result:

-- This is the actual result on PHP-CLI
-- PHP Version => 5.2.6-3ubuntu4.2
-- 
-- System => Linux wintermute 2.6.28-16-generic #55-Ubuntu SMP Tue Oct
20 19:48:24 UTC 2009 i686
-- Build Date => Aug 21 2009 19:12:00
-- Server API => Command Line Interface

HTTP/1.0 200 OK
Date: Mon, 16 Nov 2009 18:39:02 GMT
Expires: Mon, 16 Nov 2009 18:54:02 GMT
Cache-Control: max-age=900
Xontent-Length:
Connection: Close
Via: NS-CACHE-6.0:   4
Server: Apache/2.2.3 (Red Hat)
X-Powered-By: PHP/5.1.6
Content-Type: text/html; charset=UTF-8


Actual result:
--
-- PHP Version => 5.2.6-3ubuntu4.2
-- 
-- System => Linux wintermute 2.6.28-16-generic #55-Ubuntu SMP Tue Oct
20 19:48:24 UTC 2009 i686
-- Build Date => Aug 21 2009 18:45:50
-- Server API => Apache 2.0 Handler 


Warning: fsockopen() [function.fsockopen]: SSL: Success in
/home/user/public_html/fsockopen.php on line 14

Warning: fsockopen() [function.fsockopen]: Failed to enable crypto in
/home/user/public_html/fsockopen.php on line 14

Warning: fsockopen() [function.fsockopen]: unable to connect to
ssl://www.mozilla.com:443 (Unknown error) in
/home/user/public_html/fsockopen.php on line 14





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



#49764 [NoF->Fbk]: number_format() fails (randomly?)

2009-12-13 Thread felipe
 ID:   49764
 Updated by:   fel...@php.net
 Reported By:  tec at baufi24 dot de
-Status:   No Feedback
+Status:   Feedback
 Bug Type: Math related
 Operating System: Windows Server 2003 RC2
 PHP Version:  5.2.11
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2009-10-12 01:00:00] 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".



[2009-10-04 18:03:36] j...@php.net

Please try using this snapshot:

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

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





[2009-10-04 08:55:27] tec at baufi24 dot de

Description:

Using number_format will sometimes produce a very hard error. This
phenomenon is not persistent. Sometimes i will see that, but i dont know
what conditions are necessary to reproduce

Reproduce code:
---
$value = 2900;
echo "Unformated: ".$value."";
echo "Using number_format: ".number_format($value, 2, ',', '.')."";
echo "Crosscheck: ".number_format(2900, 2, ',', '.')."";

Expected result:

Unformated: 2900
Using number_format: 2.900,00
Crosscheck: 2.900,00

Actual result:
--
Unformated: 2900
Using number_format: 2.8:0,00
Crosscheck: 2.8:0,00





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



#49733 [NoF->Csd]: mb_internal_encoding() value gets reset by parse_str()

2009-12-13 Thread felipe
 ID:   49733
 Updated by:   fel...@php.net
 Reported By:  dcz at phpbb-seo dot com
-Status:   No Feedback
+Status:   Closed
 Bug Type: mbstring related
 Operating System: win xp
 PHP Version:  5.3.0


Previous Comments:


[2009-10-22 15:32:18] php dot net at chris dot cs278 dot org

Fixed under 5.3-latest



[2009-10-10 01:00:00] 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".



[2009-10-01 17:24:21] dcz at phpbb-seo dot com

I just tried with another install of mine, and 5.2.6-2ubuntu4.3 works
as expected.

Unfortunately, it won't be simple for me at this point to try other
versions, the test is fairly simple though for anyone running the latest
package.

Regards,

dcz



[2009-10-01 16:20:45] j...@php.net

Please try using this snapshot:

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

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





[2009-10-01 09:19:24] dcz at phpbb-seo dot com

Forgot to mention : 
ini_set("mbstring.internal_encoding", 'UTF-8');
fixes the issue the same way it did for php5.2.10



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/49733

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



#49700 [NoF->Ver]: memory leaks in php_date.c if garbage collector is enabled

2009-12-13 Thread felipe
 ID:   49700
 Updated by:   fel...@php.net
 Reported By:  indey...@php.net
-Status:   No Feedback
+Status:   Verified
 Bug Type: Date/time related
 Operating System: Mac OS X 10.6.1
 PHP Version:  5.3SVN-2009-09-28 (SVN)


Previous Comments:


[2009-12-05 01:00:01] 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".



[2009-11-27 18:08:58] j...@php.net

Please try using this snapshot:

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

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





[2009-10-07 05:48:38] ahar...@php.net

I can reproduce this with the current PHP_5_3 and with a custom-built
vanilla 5.3.0 on OS X 10.6.1, so long as the new garbage collector is
enabled via zend.enable_gc or gc_enable(). Linux is unaffected, as is
the php 5.3.0 build provided with OS X 10.6. The build I'm using is an
x86_64 compile, as the reporter's also appears to be. Most of the leaks
appear to be in time zone handling routines.

Interestingly, I can actually get this to segfault for certain numbers
of loop iterations with the current PHP_5_3 head, but not with 5.3.0.
This works fine up to and including 9993 iterations of the loop,
segfaults between 9994-9996 iterations, and then generates the memory
leak output in the report from 9997 iterations onwards.

Relevant gdb output (using PHP_5_3):

(gdb) r /tmp/test.php 9995
Starting program: /Users/adam/Trees/php5.3-200910070430/sapi/cli/php
/tmp/test.php 9995
Reading symbols for shared libraries .+. done

Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: KERN_INVALID_ADDRESS at address: 0x
0x7fff872b5c00 in strlen ()
(gdb) bt
#0  0x7fff872b5c00 in strlen ()
#1  0x000165b2 in date_object_get_properties
(object=0x7fff5fbff280) at
/Users/adam/Trees/php5.3-200910070430/ext/date/php_date.c:2101
#2  0x0001003da593 in zobj_mark_grey (obj=0x1020dc328,
pz=0x7fff5fbff280) at
/Users/adam/Trees/php5.3-200910070430/Zend/zend_gc.c:383
#3  0x0001003da6a9 in gc_mark_roots () at
/Users/adam/Trees/php5.3-200910070430/Zend/zend_gc.c:410
#4  0x0001003daff1 in gc_collect_cycles () at
/Users/adam/Trees/php5.3-200910070430/Zend/zend_gc.c:628
#5  0x0001003d9c2c in gc_zval_possible_root (zv=0x1009be148) at
/Users/adam/Trees/php5.3-200910070430/Zend/zend_gc.c:166
#6  0x00010039f0a7 in _zval_ptr_dtor (zval_ptr=0x1007fdff8,
__zend_filename=0x1004ea278
"/Users/adam/Trees/php5.3-200910070430/main/main.c", __zend_lineno=1585)
at zend_gc.h:183
#7  0x000100331de8 in php_request_shutdown (dummy=0x0) at
/Users/adam/Trees/php5.3-200910070430/main/main.c:1585
#8  0x00010049e057 in main (argc=3, argv=0x7fff5fbff820) at
/Users/adam/Trees/php5.3-200910070430/sapi/cli/php_cli.c:1371
(gdb) frame 1
#1  0x000165b2 in date_object_get_properties
(object=0x7fff5fbff280) at
/Users/adam/Trees/php5.3-200910070430/ext/date/php_date.c:2101
2101ZVAL_STRING(zv, 
dateobj->time->tz_info->name, 1);
(gdb) print *dateobj->time->tz_info
$1 = {
  name = 0x6 , 
  ttisgmtcnt = 6, 
  ttisstdcnt = 0, 
  leapcnt = 12, 
  timecnt = 18, 
  typecnt = 4, 
  charcnt = 4, 
  trans = 0x0, 
  trans_idx = 0x0, 
  type = 0x0, 
  timezone_abbr = 0x0, 
  leap_times = 0x0, 
  bc = 1 '\001', 
  location = {
country_code = "AU", 
latitude = -31.953, 
longitude = 115.850002, 
comments = 0x0
  }
}

The value of dateobj->time->tz_info->name is not consistent between
runs, even with the same number of iterations, but it's always an
invalid pointer value between 0 and 15, inclusive.

For completeness, the test script I'm using:



And the entire contents of the php.ini being used:

date.timezone = Australia/Perth

Let me know if there's anything I can do to help debug.


tl;dr: OS X specific; only occurs with the new garbage collector
enabled; possibly related to or at least triggered by something in the
time zone code.



[2009-10-02 22:44:55] f...@php.net

Probably Mac OS only...

Couldn't reproduce with latest snap (php5.3-200910022030) on Linux x86
without running into a memory_limit of 512 MB with CLI



[2009-09-28 17:25:28] indey...@php.net

Description:

If garbage-collector is enabled and large quantity of DateTime objects
is created, php reports memory leaks

Reproduce code:
---
http://bugs.php.net/?id=49700&edit=1



#50209 [NoF->Csd]: Compiling with libedit cannot find readline.h

2009-12-13 Thread felipe
 ID:   50209
 Updated by:   fel...@php.net
 Reported By:  tcallawa at redhat dot com
-Status:   No Feedback
+Status:   Closed
 Bug Type: Compile Failure
 Operating System: Linux (Fedora)
-PHP Version:  5.3.0
+PHP Version:  5.2, 5.3, 6
-Assigned To:  
+Assigned To:  felipe
 New Comment:

This bug has been fixed in SVN.

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.

Thanks for the patch!


Previous Comments:


[2009-12-13 17:06:49] s...@php.net

Automatic comment from SVN on behalf of felipe
Revision: http://svn.php.net/viewvc/?view=revision&revision=292081
Log: - Fixed bug #50209 (Compiling with libedit cannot find readline.h)
  (patch by tcallawa at redhat dot com)



[2009-11-26 01:00:01] 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".



[2009-11-18 14:26:01] j...@php.net

Please try using this snapshot:

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

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





[2009-11-17 21:49:34] tcallawa at redhat dot com

Description:

The PHP code assumes that even with libedit in use (instead of
readline), that the header can be found in readline/readline.h.

libedit installs its "readline.h" into editline/ (to avoid the obvious
conflict with readline).

Accordingly, configure claims that libedit is not properly installed,
when it is. I've written a straightforward patch to fix this:

http://spot.fedorapeople.org/php-5.3.0-libedit.patch

It is also possible to use pkgconfig to ask libedit for its include
flags (and cflags), which would return "-I/usr/include/editline", but as
that was slightly more intrusive, I did not go down that road.

In addition, on a system where readline-devel and libedit-devel are
both installed, the existing code checking for
/usr/include/readline-devel will cause a false positive when checking
for libedit, and will end up doing a compile with readline's headers and
libedit's library.

Reproduce code:
---
./configure --without-readline --with-libedit


Expected result:

checking for libedit readline replacement... yes
checking for readline in -ledit... yes


Actual result:
--
checking for libedit readline replacement... yes
configure: error: Please reinstall libedit - I cannot find readline.h






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



#41243 [Com]: How to use ZIPARCHIVE::CM_STORE

2009-12-13 Thread made at up dot address
 ID:  41243
 Comment by:  made at up dot address
 Reported By: joel dot alexandre at gmail dot com
 Status:  Open
 Bug Type:Feature/Change Request
 PHP Version: 5.x
 Assigned To: pajoye
 New Comment:

Please implement the ability to store files uncompressed in a zip
archive.

Without this, it is not possible to create epub documents using php, as
the standards require that a particular file is always added to the
archive uncompressed.

http://www.idpf.org/2007/ops/OPS_2.0_final_spec.html


Previous Comments:


[2009-05-26 11:31:03] andreidf at yahoo dot com

"Future versions will let you specify the compression mode and
method."

When? :)



[2007-05-01 18:05:51] paj...@php.net

"This applies to all ZIPARCHIVE::FL_* "

See:
http://www.php.net/manual/en/function.ziparchive-statname.php

That's where some of the flags can be used. Each function doc defines
which flag or option can be used.

"and ZIPARCHIVE::CM_* flags."

The compression method (and mode) are read only for now. It is part of
the entry info returned by the stat* functions.

Future versions will let you specify the compression mode and method.

Move to feature request and assign to me (it is in my todo but at least
this bug may help other to figure it out or to provide patches :).



[2007-04-30 16:05:00] joel dot alexandre at gmail dot com

Description:

How can the constant ZIPARCHIVE::CM_STORE be used to create a zip
archive. That info is missing in the documentation.

This applies to all ZIPARCHIVE::FL_* and ZIPARCHIVE::CM_* flags.






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



#50464 [Opn->Csd]: declare encoding doesn't work with

2009-12-13 Thread felipe
 ID:   50464
 Updated by:   fel...@php.net
 Reported By:  marco dot weber at uni-trier dot de
-Status:   Open
+Status:   Closed
 Bug Type: *General Issues
 Operating System: ANY
 PHP Version:  5.3.1
-Assigned To:  
+Assigned To:  felipe
 New Comment:

This bug has been fixed in SVN.

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:


[2009-12-13 15:18:59] s...@php.net

Automatic comment from SVN on behalf of felipe
Revision: http://svn.php.net/viewvc/?view=revision&revision=292078
Log: - Fixed bug #50464 (declare encoding doesn't work with)
# The bug (BC) only happens in this branch.



[2009-12-13 01:00:00] marco dot weber at uni-trier dot de

http://lists.typo3.org/pipermail/flow3-general/2009-December/42.html



[2009-12-13 00:31:11] marco dot weber at uni-trier dot de

Description:

When using the the declare encoding statement in your php script, you
will get an fatal error, when you try to include a subscript with a
defined encoding.

This only happens with php5.3.x version that was compiled with
'--enable-zend-multibyte'

When i'm using a php5.3.x version WITHOUT '--enable-zend-multibyte',
there is no fatal error. And everything works as expected.

Reproduce code:
---
i used a php5.3.1 with '--enable-zend-multibyte'

just try to call the index.php binary

index.php file:



sub.inc.php file:



Expected result:

NO FATAL ERROR...
( Same result as WITHOUT '--enable-zend-multibyte' )

Actual result:
--
Fatal error: Encoding declaration pragma must be the very first
statement in the script in /home/mweber/public_html/sub.inc.php on line
2





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