Bug #52434 [Bgs]: mysqlnd: host cannot be localhost when connecting to tcp port

2010-07-25 Thread anthon dot pang at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=52434edit=1

 ID:   52434
 User updated by:  anthon dot pang at gmail dot com
 Reported by:  anthon dot pang at gmail dot com
-Summary:  mysqlnd: host cannot be a hostname
+Summary:  mysqlnd: host cannot be localhost when connecting to
   tcp port
 Status:   Bogus
 Type: Bug
 Package:  MySQL related
 Operating System: Ubuntu 10.04
 PHP Version:  5.3.3

 New Comment:

Seriously?



http://www.php.net/manual/en/ref.pdo-mysql.connection.php gives two
examples:



mysql:host=localhost;port=3307;dbname=testdb

mysql:unix_socket=/tmp/mysql.sock;dbname=testdb



And my DSN (constructed by Zend Framework) follows the first example. 
Where does it say I have to define the unix socket in php.ini if I
intend to connect using the tcp port?



Here's the fix:



--- mysqlnd.c.bak   2010-07-25 02:47:29.0 -0400

+++ mysqlnd.c   2010-07-25 02:49:37.0 -0400

@@ -635,7 +635,7 @@

char * transport = NULL;

int transport_len;

 #ifndef PHP_WIN32

-   if (host_len == sizeof(localhost) - 1 
!strncasecmp(host, localhost, host_len)) {

+   if (!port  host_len == sizeof(localhost) - 1 
!strncasecmp(host, localhost, host_len)) {

DBG_INF_FMT(socket=%s, socket? socket:n/a);

if (!socket) {

socket = /tmp/mysql.sock;


Previous Comments:

[2010-07-25 06:31:41] dtajchre...@php.net

Tell PHP where your mysql.sock file is via the DSN or
pdo_mysql.default_socket in 

the php.ini file and your error will go away. Your conclusion is way
off. 



http://www.php.net/manual/en/ref.pdo-mysql.connection.php


[2010-07-25 04:42:45] anthon dot pang at gmail dot com

Description:

With PDO_MYSQL, if PHP is linked with mysql client libraries (instead of
mysqlnd), the DSN can contain a host parameter with a hostname, e.g.,
host=localhost.



However, with mysqlnd, the host has to be an ip address, e.g.,
host=127.0.0.1.  This occurs for '--with-mysqli=mysqlnd' or
'--with-pdo-mysql=mysqlnd'.  It appears mysqlnd wants to use a Unix
socket even though the port is explictly specified,



This backward incompatibility surprises users migrating from php 5.2.x
and find their apps suddenly can't connect.



MySQL 5.1.41

Test script:
---
From Zend Framework 1.10.6:



$_isConnected = @mysqli_real_connect(

$this-_connection,

$this-_config['host'],

$this-_config['username'],

$this-_config['password'],

$this-_config['dbname'],

$port

);

Expected result:

Expect it to connect.



Actual result:
--
Warning: PDO::__construct() [pdo.--construct]: [2002] No such file or
directory (trying to connect via unix:///tmp/mysql.sock) in
/var/www/libs/Zend/Db/Adapter/Pdo/Abstract.php on line 129

SQLSTATE[HY000] [2002] No such file or directory






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


Bug #52429 [Fbk-Opn]: date_default_timezone error

2010-07-25 Thread patrice dot flahault at accessprinting dot fr
Edit report at http://bugs.php.net/bug.php?id=52429edit=1

 ID:   52429
 User updated by:  patrice dot flahault at accessprinting dot fr
 Reported by:  patrice dot flahault at accessprinting dot fr
 Summary:  date_default_timezone error
-Status:   Feedback
+Status:   Open
 Type: Bug
 Package:  Date/time related
 Operating System: centos 5.5
 PHP Version:  5.3.3

 New Comment:

Ramus,



My code is : 

date_default_timezone_set('Europe/Paris');

echo date('H:i e') .'br /';

date_default_timezone_set('Europe/Madrid');

echo date('H:i e') ;



You can try it at : www.accessprinting.fr/test/test.php


Previous Comments:

[2010-07-24 20:30:23] dtajchre...@php.net

Looks fine to me..



[da...@lyon ~]$ php t.php 

int(1279996161)

string(25) 2010-07-24T20:29:21+02:00

[da...@lyon ~]$ cat t.php 

?php

var_dump(time());

date_default_timezone_set('Europe/Paris');

var_dump(date('c'));


[2010-07-24 18:09:40] ras...@php.net

Are you sure you haven't done something else wrong?  I just fired up a
Centos VM 

and tried it:



?php

date_default_timezone_set('Europe/Paris');

echo date(H:i:s);

echo \n;

date_default_timezone_set('Europe/Madrid');

echo date(H:i:s);



The output is:



18:08:25

18:08:25



No 6-hour difference there.


[2010-07-24 18:01:48] patrice dot flahault at accessprinting dot fr

Description:

The time zone Europe/Paris gives a wrong time.



date_default_timezone_set('Europe/Paris');

should be the same as :

date_default_timezone_set('Europe/Madrid'); 



but there is a 6 hour difference.









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


Bug #52429 [Opn]: date_default_timezone error

2010-07-25 Thread patrice dot flahault at accessprinting dot fr
Edit report at http://bugs.php.net/bug.php?id=52429edit=1

 ID:   52429
 User updated by:  patrice dot flahault at accessprinting dot fr
 Reported by:  patrice dot flahault at accessprinting dot fr
 Summary:  date_default_timezone error
 Status:   Open
 Type: Bug
 Package:  Date/time related
 Operating System: centos 5.5
 PHP Version:  5.3.3

 New Comment:

There is one difference my php version is 5.3.2


Previous Comments:

[2010-07-25 11:45:19] patrice dot flahault at accessprinting dot fr

Ramus,



My code is : 

date_default_timezone_set('Europe/Paris');

echo date('H:i e') .'br /';

date_default_timezone_set('Europe/Madrid');

echo date('H:i e') ;



You can try it at : www.accessprinting.fr/test/test.php


[2010-07-24 20:30:23] dtajchre...@php.net

Looks fine to me..



[da...@lyon ~]$ php t.php 

int(1279996161)

string(25) 2010-07-24T20:29:21+02:00

[da...@lyon ~]$ cat t.php 

?php

var_dump(time());

date_default_timezone_set('Europe/Paris');

var_dump(date('c'));


[2010-07-24 18:09:40] ras...@php.net

Are you sure you haven't done something else wrong?  I just fired up a
Centos VM 

and tried it:



?php

date_default_timezone_set('Europe/Paris');

echo date(H:i:s);

echo \n;

date_default_timezone_set('Europe/Madrid');

echo date(H:i:s);



The output is:



18:08:25

18:08:25



No 6-hour difference there.


[2010-07-24 18:01:48] patrice dot flahault at accessprinting dot fr

Description:

The time zone Europe/Paris gives a wrong time.



date_default_timezone_set('Europe/Paris');

should be the same as :

date_default_timezone_set('Europe/Madrid'); 



but there is a 6 hour difference.









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


Bug #52429 [Opn-Bgs]: date_default_timezone error

2010-07-25 Thread derick
Edit report at http://bugs.php.net/bug.php?id=52429edit=1

 ID:   52429
 Updated by:   der...@php.net
 Reported by:  patrice dot flahault at accessprinting dot fr
 Summary:  date_default_timezone error
-Status:   Open
+Status:   Bogus
 Type: Bug
 Package:  Date/time related
 Operating System: centos 5.5
 PHP Version:  5.3.3

 New Comment:

Centos patches PHP's date/time stuff in odd ways. This works fine.


Previous Comments:

[2010-07-25 11:51:57] patrice dot flahault at accessprinting dot fr

There is one difference my php version is 5.3.2


[2010-07-25 11:45:19] patrice dot flahault at accessprinting dot fr

Ramus,



My code is : 

date_default_timezone_set('Europe/Paris');

echo date('H:i e') .'br /';

date_default_timezone_set('Europe/Madrid');

echo date('H:i e') ;



You can try it at : www.accessprinting.fr/test/test.php


[2010-07-24 20:30:23] dtajchre...@php.net

Looks fine to me..



[da...@lyon ~]$ php t.php 

int(1279996161)

string(25) 2010-07-24T20:29:21+02:00

[da...@lyon ~]$ cat t.php 

?php

var_dump(time());

date_default_timezone_set('Europe/Paris');

var_dump(date('c'));


[2010-07-24 18:09:40] ras...@php.net

Are you sure you haven't done something else wrong?  I just fired up a
Centos VM 

and tried it:



?php

date_default_timezone_set('Europe/Paris');

echo date(H:i:s);

echo \n;

date_default_timezone_set('Europe/Madrid');

echo date(H:i:s);



The output is:



18:08:25

18:08:25



No 6-hour difference there.


[2010-07-24 18:01:48] patrice dot flahault at accessprinting dot fr

Description:

The time zone Europe/Paris gives a wrong time.



date_default_timezone_set('Europe/Paris');

should be the same as :

date_default_timezone_set('Europe/Madrid'); 



but there is a 6 hour difference.









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


Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread cari dot bantuan at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   cari dot bantuan at gmail dot com
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

Reddit.com rules, baby!


Previous Comments:

[2010-07-25 06:48:35] dtajchre...@php.net

All your coin are belong to us


[2010-07-25 06:21:01] dh123lh1 at hotmail dot com

Description:

where its supposed to pay off the farmvill Iqtest and tell me my
resultsI got this instead of my million farmville coins, i have done
this Iq test please pay my million coins in facebooks farmville



http://www.quizulous.com/toolbar/newaccount/conduit



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'

Test script:
---
I didnt write this 

Expected result:

you get your client quizloos to have farmville pay my million coins

Actual result:
--
stack trace from the page it brought up rather than my reward



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'






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


[PHP-BUG] Bug #52438 [NEW]: Parser error on a simple example

2010-07-25 Thread dagdamor10 at mail dot ru
From: 
Operating system: Windows
PHP version:  5.2.14
Package:  Scripting Engine problem
Bug Type: Bug
Bug description:Parser error on a simple example

Description:

My framework (http://www.phpc.ru) uses automatic code generation, and when
I was fine-tuning it, I discovered a weird error in the PHP parser.

Test script:
---
?php



function test() {?This is a test.?php}



?

Expected result:

Empty screen (since the function is never called)

Actual result:
--
Parse error: syntax error, unexpected $end in index.php on line 6





If you add a space character between ?php and }, it works just fine.



I simply used a workaround, but maybe this report will be useful for you.

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



Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread fraser dot wade at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   fraser dot wade at gmail dot com
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

This is what has become of our internet, friends.  It's time to make a
new one.


Previous Comments:

[2010-07-25 15:58:08] cari dot bantuan at gmail dot com

Reddit.com rules, baby!


[2010-07-25 06:48:35] dtajchre...@php.net

All your coin are belong to us


[2010-07-25 06:21:01] dh123lh1 at hotmail dot com

Description:

where its supposed to pay off the farmvill Iqtest and tell me my
resultsI got this instead of my million farmville coins, i have done
this Iq test please pay my million coins in facebooks farmville



http://www.quizulous.com/toolbar/newaccount/conduit



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'

Test script:
---
I didnt write this 

Expected result:

you get your client quizloos to have farmville pay my million coins

Actual result:
--
stack trace from the page it brought up rather than my reward



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'






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


Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread dr-boot at gmx dot net
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   dr-boot at gmx dot net
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

So how did you score on that IQ test?


Previous Comments:

[2010-07-25 16:08:14] fraser dot wade at gmail dot com

This is what has become of our internet, friends.  It's time to make a
new one.


[2010-07-25 15:58:08] cari dot bantuan at gmail dot com

Reddit.com rules, baby!


[2010-07-25 06:48:35] dtajchre...@php.net

All your coin are belong to us


[2010-07-25 06:21:01] dh123lh1 at hotmail dot com

Description:

where its supposed to pay off the farmvill Iqtest and tell me my
resultsI got this instead of my million farmville coins, i have done
this Iq test please pay my million coins in facebooks farmville



http://www.quizulous.com/toolbar/newaccount/conduit



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'

Test script:
---
I didnt write this 

Expected result:

you get your client quizloos to have farmville pay my million coins

Actual result:
--
stack trace from the page it brought up rather than my reward



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'






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


Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread keysal at aol dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   keysal at aol dot com
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

Consequences will never be the same!


Previous Comments:

[2010-07-25 16:36:46] dr-boot at gmx dot net

So how did you score on that IQ test?


[2010-07-25 16:08:14] fraser dot wade at gmail dot com

This is what has become of our internet, friends.  It's time to make a
new one.


[2010-07-25 15:58:08] cari dot bantuan at gmail dot com

Reddit.com rules, baby!


[2010-07-25 06:48:35] dtajchre...@php.net

All your coin are belong to us


[2010-07-25 06:21:01] dh123lh1 at hotmail dot com

Description:

where its supposed to pay off the farmvill Iqtest and tell me my
resultsI got this instead of my million farmville coins, i have done
this Iq test please pay my million coins in facebooks farmville



http://www.quizulous.com/toolbar/newaccount/conduit



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'

Test script:
---
I didnt write this 

Expected result:

you get your client quizloos to have farmville pay my million coins

Actual result:
--
stack trace from the page it brought up rather than my reward



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'






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


Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread hellno at hellfire dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   hellno at hellfire dot com
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

Grow some weed on Farmville, and sell it on Mafia wars. Earn LOTS of
money.


Previous Comments:

[2010-07-25 16:53:00] keysal at aol dot com

Consequences will never be the same!


[2010-07-25 16:36:46] dr-boot at gmx dot net

So how did you score on that IQ test?


[2010-07-25 16:08:14] fraser dot wade at gmail dot com

This is what has become of our internet, friends.  It's time to make a
new one.


[2010-07-25 15:58:08] cari dot bantuan at gmail dot com

Reddit.com rules, baby!


[2010-07-25 06:48:35] dtajchre...@php.net

All your coin are belong to us




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/bug.php?id=52435


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


Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread digg-sux at reddit dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   digg-sux at reddit dot com
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

Reddit.com rules!



Digg sucks balls.


Previous Comments:

[2010-07-25 17:14:55] hellno at hellfire dot com

Grow some weed on Farmville, and sell it on Mafia wars. Earn LOTS of
money.


[2010-07-25 16:53:00] keysal at aol dot com

Consequences will never be the same!


[2010-07-25 16:36:46] dr-boot at gmx dot net

So how did you score on that IQ test?


[2010-07-25 16:08:14] fraser dot wade at gmail dot com

This is what has become of our internet, friends.  It's time to make a
new one.


[2010-07-25 15:58:08] cari dot bantuan at gmail dot com

Reddit.com rules, baby!




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/bug.php?id=52435


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


Bug #48520 [Com]: openssl_csr_new does not allow multiple values/field in dn

2010-07-25 Thread nirfri at hotmail dot com
Edit report at http://bugs.php.net/bug.php?id=48520edit=1

 ID:   48520
 Comment by:   nirfri at hotmail dot com
 Reported by:  php at divinehawk dot com
 Summary:  openssl_csr_new does not allow multiple values/field
   in dn
 Status:   Assigned
 Type: Bug
 Package:  OpenSSL related
 Operating System: *
 PHP Version:  5.2.9
 Assigned To:  pajoye

 New Comment:

This patch doesn't work on multiple CNs.



commonName = array(test2, test)



is this fixed at 5.3.2 ?


Previous Comments:

[2009-06-10 18:38:44] php at divinehawk dot com

Patch against 5.3



--- openssl.c   20 Apr 2009 09:44:29 -  1.98.2.5.2.41.2.29

+++ openssl.c   10 Jun 2009 18:36:57 -

@@ -1998,7 +1998,9 @@

CONF_VALUE * v;

X509_NAME * subj;

HashPosition hpos;

+   HashPosition subhpos;

zval ** item;

+   zval ** subitem;



subj = X509_REQ_get_subject_name(csr);

/* apply values from the dn hash */

@@ -2010,6 +2012,29 @@



zend_hash_get_current_key_ex(HASH_OF(dn), strindex, 
strindexlen,
intindex, 0, hpos);

 

+   if(Z_TYPE_PP(item) == IS_ARRAY  strindex) {

+   /* multi-value string */

+   int nid;

+   nid = OBJ_txt2nid(strindex);

+   

+   if (nid != NID_undef) {

+   
zend_hash_internal_pointer_reset_ex(HASH_OF(*item), subhpos);

+   
while(zend_hash_get_current_data_ex(HASH_OF(*item),
(void**)subitem, subhpos) == SUCCESS) {

+   convert_to_string_ex(subitem);

+   if 
(!X509_NAME_add_entry_by_NID(subj, nid, MBSTRING_ASC, 

+   (unsigned 
char*)Z_STRVAL_PP(subitem), -1, -1, 1)) {

+   php_error_docref(NULL 
TSRMLS_CC, E_WARNING, dn:
add_entry_by_NID %d - %s (failed), nid, Z_STRVAL_PP(subitem));

+   return FAILURE;

+   }

+   
zend_hash_move_forward_ex(HASH_OF(dn), subhpos);

+   }

+   } else {

+   php_error_docref(NULL TSRMLS_CC, 
E_WARNING, dn: %s is not a
recognized name, strindex);

+   }

+   zend_hash_move_forward_ex(HASH_OF(dn), hpos);

+   continue;

+   }

+

convert_to_string_ex(item);

 

if (strindex) {


[2009-06-10 16:29:39] paj...@php.net



Thanks for your work :)



We need a patch against 5.3+ as well as test cases.



PHP 5.2 won't get new features (only bug fixes).






[2009-06-10 16:25:12] php at divinehawk dot com

Patch:



--- php-5.2.9/ext/openssl/openssl.c.orig2009-06-10 06:55:27.0
-0400

+++ php-5.2.9/ext/openssl/openssl.c 2009-06-10 06:56:56.0 -0400

@@ -1707,7 +1707,9 @@

CONF_VALUE * v;

X509_NAME * subj;

HashPosition hpos;

+   HashPosition subhpos;

zval ** item;

+   zval ** subitem;



subj = X509_REQ_get_subject_name(csr);

/* apply values from the dn hash */

@@ -1719,6 +1721,32 @@



zend_hash_get_current_key_ex(HASH_OF(dn), strindex, 
strindexlen,
intindex, 0, hpos);

 

+   if(Z_TYPE_PP(item) == IS_ARRAY  strindex)

+   {

+   /* multi-value string */

+   int nid;

+   nid = OBJ_txt2nid(strindex);

+   

+   if (nid != NID_undef) {

+   
zend_hash_internal_pointer_reset_ex(HASH_OF(*item), subhpos);

+   
while(zend_hash_get_current_data_ex(HASH_OF(*item),
(void**)subitem, subhpos) == SUCCESS)

+   {

+   convert_to_string_ex(subitem);

+   if 
(!X509_NAME_add_entry_by_NID(subj, nid, 

Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread shevegen at linuxmail dot org
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   shevegen at linuxmail dot org
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

Vim is better than Emacs.


Previous Comments:

[2010-07-25 17:29:50] digg-sux at reddit dot com

Reddit.com rules!



Digg sucks balls.


[2010-07-25 17:14:55] hellno at hellfire dot com

Grow some weed on Farmville, and sell it on Mafia wars. Earn LOTS of
money.


[2010-07-25 16:53:00] keysal at aol dot com

Consequences will never be the same!


[2010-07-25 16:36:46] dr-boot at gmx dot net

So how did you score on that IQ test?


[2010-07-25 16:08:14] fraser dot wade at gmail dot com

This is what has become of our internet, friends.  It's time to make a
new one.




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/bug.php?id=52435


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


[PHP-BUG] Bug #52439 [NEW]: Static and non-static variable name collision in a class declaration

2010-07-25 Thread shiranai7 at hotmail dot com
From: 
Operating system: Win
PHP version:  5.3.3
Package:  Class/Object related
Bug Type: Bug
Bug description:Static and non-static variable name collision in a class 
declaration

Description:

It seems impossible to have two variables - one static and one not - with
same name in a class declaration. But these are two completely different
variables!

Test script:
---
?php

// this results in a fatal error

class Test {

public static $Foo = 'iamstatic';

public $Foo = 'iamNOTstatic';

}

// this works

class Test {

public static $Foo = 'iamstatic';

}

$Baz = new Test();

$Baz-Foo = 'iamNOTstatic';

echo $Baz-Foo.\n;

echo Test::$Foo;

/* Result:

iamNOTstatic

iamstatic

*/

?

Expected result:

No errors.

Actual result:
--
Fatal error: Cannot redeclare Test::$Foo in *path* on line 6

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



Bug #52439 [Opn-Bgs]: Static and non-static variable name collision in a class declaration

2010-07-25 Thread pajoye
Edit report at http://bugs.php.net/bug.php?id=52439edit=1

 ID:   52439
 Updated by:   paj...@php.net
 Reported by:  shiranai7 at hotmail dot com
 Summary:  Static and non-static variable name collision in a
   class declaration
-Status:   Open
+Status:   Bogus
 Type: Bug
 Package:  Class/Object related
 Operating System: Win
 PHP Version:  5.3.3

 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:

[2010-07-25 17:48:33] shiranai7 at hotmail dot com

Description:

It seems impossible to have two variables - one static and one not -
with same name in a class declaration. But these are two completely
different variables!

Test script:
---
?php

// this results in a fatal error

class Test {

public static $Foo = 'iamstatic';

public $Foo = 'iamNOTstatic';

}

// this works

class Test {

public static $Foo = 'iamstatic';

}

$Baz = new Test();

$Baz-Foo = 'iamNOTstatic';

echo $Baz-Foo.\n;

echo Test::$Foo;

/* Result:

iamNOTstatic

iamstatic

*/

?

Expected result:

No errors.

Actual result:
--
Fatal error: Cannot redeclare Test::$Foo in *path* on line 6






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


Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread notreal at all dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   notreal at all dot com
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

reddit sucks balls!


Previous Comments:

[2010-07-25 17:45:58] shevegen at linuxmail dot org

Vim is better than Emacs.


[2010-07-25 17:29:50] digg-sux at reddit dot com

Reddit.com rules!



Digg sucks balls.


[2010-07-25 17:14:55] hellno at hellfire dot com

Grow some weed on Farmville, and sell it on Mafia wars. Earn LOTS of
money.


[2010-07-25 16:53:00] keysal at aol dot com

Consequences will never be the same!


[2010-07-25 16:36:46] dr-boot at gmx dot net

So how did you score on that IQ test?




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/bug.php?id=52435


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


Bug #52439 [Com]: Static and non-static variable name collision in a class declaration

2010-07-25 Thread shiranai7 at hotmail dot com
Edit report at http://bugs.php.net/bug.php?id=52439edit=1

 ID:   52439
 Comment by:   shiranai7 at hotmail dot com
 Reported by:  shiranai7 at hotmail dot com
 Summary:  Static and non-static variable name collision in a
   class declaration
 Status:   Bogus
 Type: Bug
 Package:  Class/Object related
 Operating System: Win
 PHP Version:  5.3.3

 New Comment:

Not a bug? What is this supposed to be then? Correct behavior? I think
not. This is not a support question. I am just reporting that PHP
behaves wrong - treats static and non-static variable as one in first
example.



Do I really have to explain that static variable is not THE SAME as
non-static variable and that I am NOT redeclaring anything? Duh.



And - if you are about to reply with another silly predefined answer
then better don't answer at all, thank you.


Previous Comments:

[2010-07-25 17:50:44] paj...@php.net

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.




[2010-07-25 17:48:33] shiranai7 at hotmail dot com

Description:

It seems impossible to have two variables - one static and one not -
with same name in a class declaration. But these are two completely
different variables!

Test script:
---
?php

// this results in a fatal error

class Test {

public static $Foo = 'iamstatic';

public $Foo = 'iamNOTstatic';

}

// this works

class Test {

public static $Foo = 'iamstatic';

}

$Baz = new Test();

$Baz-Foo = 'iamNOTstatic';

echo $Baz-Foo.\n;

echo Test::$Foo;

/* Result:

iamNOTstatic

iamstatic

*/

?

Expected result:

No errors.

Actual result:
--
Fatal error: Cannot redeclare Test::$Foo in *path* on line 6






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


Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread fanboy at superiority dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   fanboy at superiority dot com
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

Use linux.


Previous Comments:

[2010-07-25 17:58:04] notreal at all dot com

reddit sucks balls!


[2010-07-25 17:45:58] shevegen at linuxmail dot org

Vim is better than Emacs.


[2010-07-25 17:29:50] digg-sux at reddit dot com

Reddit.com rules!



Digg sucks balls.


[2010-07-25 17:14:55] hellno at hellfire dot com

Grow some weed on Farmville, and sell it on Mafia wars. Earn LOTS of
money.


[2010-07-25 16:53:00] keysal at aol dot com

Consequences will never be the same!




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/bug.php?id=52435


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


Bug #52439 [Bgs]: Static and non-static variable name collision in a class declaration

2010-07-25 Thread johannes
Edit report at http://bugs.php.net/bug.php?id=52439edit=1

 ID:   52439
 Updated by:   johan...@php.net
 Reported by:  shiranai7 at hotmail dot com
 Summary:  Static and non-static variable name collision in a
   class declaration
 Status:   Bogus
 Type: Bug
 Package:  Class/Object related
 Operating System: Win
 PHP Version:  5.3.3

 New Comment:

We have one property table per class. And a property in a class can have
a static flag, so there can't be two of that name, there are things like
reflection which depend on this. This is expected and won't change.
Sorry if you don't like it.


Previous Comments:

[2010-07-25 18:17:07] shiranai7 at hotmail dot com

Not a bug? What is this supposed to be then? Correct behavior? I think
not. This is not a support question. I am just reporting that PHP
behaves wrong - treats static and non-static variable as one in first
example.



Do I really have to explain that static variable is not THE SAME as
non-static variable and that I am NOT redeclaring anything? Duh.



And - if you are about to reply with another silly predefined answer
then better don't answer at all, thank you.


[2010-07-25 17:50:44] paj...@php.net

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.




[2010-07-25 17:48:33] shiranai7 at hotmail dot com

Description:

It seems impossible to have two variables - one static and one not -
with same name in a class declaration. But these are two completely
different variables!

Test script:
---
?php

// this results in a fatal error

class Test {

public static $Foo = 'iamstatic';

public $Foo = 'iamNOTstatic';

}

// this works

class Test {

public static $Foo = 'iamstatic';

}

$Baz = new Test();

$Baz-Foo = 'iamNOTstatic';

echo $Baz-Foo.\n;

echo Test::$Foo;

/* Result:

iamNOTstatic

iamstatic

*/

?

Expected result:

No errors.

Actual result:
--
Fatal error: Cannot redeclare Test::$Foo in *path* on line 6






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


Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread svaant at bstuds dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   svaant at bstuds dot com
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

I love sucking balls.


Previous Comments:

[2010-07-25 18:18:15] fanboy at superiority dot com

Use linux.


[2010-07-25 17:58:04] notreal at all dot com

reddit sucks balls!


[2010-07-25 17:45:58] shevegen at linuxmail dot org

Vim is better than Emacs.


[2010-07-25 17:29:50] digg-sux at reddit dot com

Reddit.com rules!



Digg sucks balls.


[2010-07-25 17:14:55] hellno at hellfire dot com

Grow some weed on Farmville, and sell it on Mafia wars. Earn LOTS of
money.




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/bug.php?id=52435


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


Bug #52439 [Bgs]: Static and non-static variable name collision in a class declaration

2010-07-25 Thread rasmus
Edit report at http://bugs.php.net/bug.php?id=52439edit=1

 ID:   52439
 Updated by:   ras...@php.net
 Reported by:  shiranai7 at hotmail dot com
 Summary:  Static and non-static variable name collision in a
   class declaration
 Status:   Bogus
 Type: Bug
 Package:  Class/Object related
 Operating System: Win
 PHP Version:  5.3.3

 New Comment:

Do any of the scripting languages support static class var separation? 
I can't 

think of any that do off the top of my head, so I am surprised that you
would 

expect this from a scripting language.


Previous Comments:

[2010-07-25 18:25:27] johan...@php.net

We have one property table per class. And a property in a class can have
a static flag, so there can't be two of that name, there are things like
reflection which depend on this. This is expected and won't change.
Sorry if you don't like it.


[2010-07-25 18:17:07] shiranai7 at hotmail dot com

Not a bug? What is this supposed to be then? Correct behavior? I think
not. This is not a support question. I am just reporting that PHP
behaves wrong - treats static and non-static variable as one in first
example.



Do I really have to explain that static variable is not THE SAME as
non-static variable and that I am NOT redeclaring anything? Duh.



And - if you are about to reply with another silly predefined answer
then better don't answer at all, thank you.


[2010-07-25 17:50:44] paj...@php.net

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.




[2010-07-25 17:48:33] shiranai7 at hotmail dot com

Description:

It seems impossible to have two variables - one static and one not -
with same name in a class declaration. But these are two completely
different variables!

Test script:
---
?php

// this results in a fatal error

class Test {

public static $Foo = 'iamstatic';

public $Foo = 'iamNOTstatic';

}

// this works

class Test {

public static $Foo = 'iamstatic';

}

$Baz = new Test();

$Baz-Foo = 'iamNOTstatic';

echo $Baz-Foo.\n;

echo Test::$Foo;

/* Result:

iamNOTstatic

iamstatic

*/

?

Expected result:

No errors.

Actual result:
--
Fatal error: Cannot redeclare Test::$Foo in *path* on line 6






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


Bug #52433 [Opn-Bgs]: Call to undefined method mysqli::poll()

2010-07-25 Thread johannes
Edit report at http://bugs.php.net/bug.php?id=52433edit=1

 ID:   52433
 Updated by:   johan...@php.net
 Reported by:  admin at webdesignforall dot net
 Summary:  Call to undefined method mysqli::poll()
-Status:   Open
+Status:   Bogus
 Type: Bug
 Package:  MySQLi related
 Operating System: Debian 5
 PHP Version:  5.3.3

 New Comment:

MySQLi asynchronous queries only exist if PHP was compiled using mysqlnd
(--with-mysqli=myslqnd)


Previous Comments:

[2010-07-25 02:32:43] admin at webdesignforall dot net

Description:

The static method mysqli::poll doesn't exist. Using it creates a Fatal
error: Call 

to undefined method mysqli::poll() .



mysqli_poll works fine.

Test script:
---
?php

$link1 = new mysqli(localhost,root,,dba);

$link1-query(SELECT 'test', MYSQLI_ASYNC);

$done=false;

do

{

  $links = $errors = $reject = array();

  $links[] = $errors[] = $reject[] = $link1;

  if (!mysqli::poll($links, $errors, $reject, 1)) {

continue;

}

if ($result = $links[0]-reap_async_query()) {

$done=true;

}

}

while(!$done);



Expected result:

No output.

Actual result:
--
Fatal error: Call to undefined method mysqli::poll() 






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


Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread madeup at aol dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Comment by:   madeup at aol dot com
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
 Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

Can i suck your balls?


Previous Comments:

[2010-07-25 18:26:30] svaant at bstuds dot com

I love sucking balls.


[2010-07-25 18:18:15] fanboy at superiority dot com

Use linux.


[2010-07-25 17:58:04] notreal at all dot com

reddit sucks balls!


[2010-07-25 17:45:58] shevegen at linuxmail dot org

Vim is better than Emacs.


[2010-07-25 17:29:50] digg-sux at reddit dot com

Reddit.com rules!



Digg sucks balls.




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/bug.php?id=52435


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


Bug #52439 [Com]: Static and non-static variable name collision in a class declaration

2010-07-25 Thread shiranai7 at hotmail dot com
Edit report at http://bugs.php.net/bug.php?id=52439edit=1

 ID:   52439
 Comment by:   shiranai7 at hotmail dot com
 Reported by:  shiranai7 at hotmail dot com
 Summary:  Static and non-static variable name collision in a
   class declaration
 Status:   Bogus
 Type: Bug
 Package:  Class/Object related
 Operating System: Win
 PHP Version:  5.3.3

 New Comment:

I understand, thank you for your answer. This is what the first answer
should have been like.



I'm sorry but this one is about hundred times more valuable than the
other which very nicely says you are noob and go whine somewhere else.


Previous Comments:

[2010-07-25 18:31:54] ras...@php.net

Do any of the scripting languages support static class var separation? 
I can't 

think of any that do off the top of my head, so I am surprised that you
would 

expect this from a scripting language.


[2010-07-25 18:25:27] johan...@php.net

We have one property table per class. And a property in a class can have
a static flag, so there can't be two of that name, there are things like
reflection which depend on this. This is expected and won't change.
Sorry if you don't like it.


[2010-07-25 18:17:07] shiranai7 at hotmail dot com

Not a bug? What is this supposed to be then? Correct behavior? I think
not. This is not a support question. I am just reporting that PHP
behaves wrong - treats static and non-static variable as one in first
example.



Do I really have to explain that static variable is not THE SAME as
non-static variable and that I am NOT redeclaring anything? Duh.



And - if you are about to reply with another silly predefined answer
then better don't answer at all, thank you.


[2010-07-25 17:50:44] paj...@php.net

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.




[2010-07-25 17:48:33] shiranai7 at hotmail dot com

Description:

It seems impossible to have two variables - one static and one not -
with same name in a class declaration. But these are two completely
different variables!

Test script:
---
?php

// this results in a fatal error

class Test {

public static $Foo = 'iamstatic';

public $Foo = 'iamNOTstatic';

}

// this works

class Test {

public static $Foo = 'iamstatic';

}

$Baz = new Test();

$Baz-Foo = 'iamNOTstatic';

echo $Baz-Foo.\n;

echo Test::$Foo;

/* Result:

iamNOTstatic

iamstatic

*/

?

Expected result:

No errors.

Actual result:
--
Fatal error: Cannot redeclare Test::$Foo in *path* on line 6






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


Bug #52428 [Opn-Bgs]: $this isn't immutable

2010-07-25 Thread johannes
Edit report at http://bugs.php.net/bug.php?id=52428edit=1

 ID:   52428
 Updated by:   johan...@php.net
 Reported by:  tyra3l at gmail dot com
 Summary:  $this isn't immutable
-Status:   Open
+Status:   Bogus
 Type: Bug
 Package:  Scripting Engine problem
 Operating System: all
 PHP Version:  5.3.3

 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

We prevent from mistakes, we don't prevent people from hurting them
purposely. If you want you can shoot yourself in your head.


Previous Comments:

[2010-07-24 11:36:17] tyra3l at gmail dot com

Description:

As some closed bug-reports and the PHP Fatal error:  Cannot re-assign
$this 

states, the $this should be read-only/inmutable  in PHP5.

but with some tricks(variable variables mostly), you can walk-around
this 

constraint.

See the Test script.

I don't know the importance of this restriction, and with reflection you
can shoot 

you in the leg anyway, so maybe this can be left as is.

Test script:
---
?php



error_reporting(E_ALL);



$var = new StdClass();

$var-foo = 'bar';



//$this = $var; // PHP Fatal error:  Cannot re-assign $this



$GLOBALS['this'] = $var;



var_dump($this);



$var-foo = 'baz';



$foo = 'this';

$$foo = $var;



var_dump($this);



foo($this);



function foo($this){

  //global $this; // PHP Fatal error:  Cannot re-assign $this

  // $this = $GLOBALS['var']; // PHP Fatal error:  Cannot re-assign
$this

  var_dump($this);

  $GLOBALS['this']-foo = 'baw';

  $$GLOBALS['foo'] = $GLOBALS['this'];

  var_dump($this);

}



Expected result:

PHP Fatal error:  Cannot re-assign $this

for every attempt to overwrite $this

Actual result:
--
you can set $this in the global scope through $GLOBALS, with argument in


functions, and with variable variables in everywhere.






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


Bug #52428 [Bgs]: $this isn't immutable

2010-07-25 Thread tyra3l at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=52428edit=1

 ID:   52428
 User updated by:  tyra3l at gmail dot com
 Reported by:  tyra3l at gmail dot com
 Summary:  $this isn't immutable
 Status:   Bogus
 Type: Bug
 Package:  Scripting Engine problem
 Operating System: all
 PHP Version:  5.3.3

 New Comment:

Thanks for the clarification.



Did I something wrong in the report, or you just copypasted the Thank
you for 

taking the time to write to us... part of your comment?



Maybe it would be a good thing to add this conclusion to the
documentation 

(reassigning this isn't allowed, because ..., if you try it, it will
give you an 

error Cannot re-assign this... [if you really need this, you can
do...])



Tyrael


Previous Comments:

[2010-07-25 18:39:17] johan...@php.net

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

We prevent from mistakes, we don't prevent people from hurting them
purposely. If you want you can shoot yourself in your head.


[2010-07-24 11:36:17] tyra3l at gmail dot com

Description:

As some closed bug-reports and the PHP Fatal error:  Cannot re-assign
$this 

states, the $this should be read-only/inmutable  in PHP5.

but with some tricks(variable variables mostly), you can walk-around
this 

constraint.

See the Test script.

I don't know the importance of this restriction, and with reflection you
can shoot 

you in the leg anyway, so maybe this can be left as is.

Test script:
---
?php



error_reporting(E_ALL);



$var = new StdClass();

$var-foo = 'bar';



//$this = $var; // PHP Fatal error:  Cannot re-assign $this



$GLOBALS['this'] = $var;



var_dump($this);



$var-foo = 'baz';



$foo = 'this';

$$foo = $var;



var_dump($this);



foo($this);



function foo($this){

  //global $this; // PHP Fatal error:  Cannot re-assign $this

  // $this = $GLOBALS['var']; // PHP Fatal error:  Cannot re-assign
$this

  var_dump($this);

  $GLOBALS['this']-foo = 'baw';

  $$GLOBALS['foo'] = $GLOBALS['this'];

  var_dump($this);

}



Expected result:

PHP Fatal error:  Cannot re-assign $this

for every attempt to overwrite $this

Actual result:
--
you can set $this in the global scope through $GLOBALS, with argument in


functions, and with variable variables in everywhere.






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


Bug #52439 [Bgs]: Static and non-static variable name collision in a class declaration

2010-07-25 Thread pajoye
Edit report at http://bugs.php.net/bug.php?id=52439edit=1

 ID:   52439
 Updated by:   paj...@php.net
 Reported by:  shiranai7 at hotmail dot com
 Summary:  Static and non-static variable name collision in a
   class declaration
 Status:   Bogus
 Type: Bug
 Package:  Class/Object related
 Operating System: Win
 PHP Version:  5.3.3

 New Comment:

This is well documented and the comment is a standard comment to mark
bug regarding documented features as not a bug. I'm sorry if the text
looks offending but it is not, even if the word bogus could be badly
misinterpreted.



Also please understand that it is not a support channel and we have many
bugs to process, that's why pre defined messages exist.


Previous Comments:

[2010-07-25 18:38:17] shiranai7 at hotmail dot com

I understand, thank you for your answer. This is what the first answer
should have been like.



I'm sorry but this one is about hundred times more valuable than the
other which very nicely says you are noob and go whine somewhere else.


[2010-07-25 18:31:54] ras...@php.net

Do any of the scripting languages support static class var separation? 
I can't 

think of any that do off the top of my head, so I am surprised that you
would 

expect this from a scripting language.


[2010-07-25 18:25:27] johan...@php.net

We have one property table per class. And a property in a class can have
a static flag, so there can't be two of that name, there are things like
reflection which depend on this. This is expected and won't change.
Sorry if you don't like it.


[2010-07-25 18:17:07] shiranai7 at hotmail dot com

Not a bug? What is this supposed to be then? Correct behavior? I think
not. This is not a support question. I am just reporting that PHP
behaves wrong - treats static and non-static variable as one in first
example.



Do I really have to explain that static variable is not THE SAME as
non-static variable and that I am NOT redeclaring anything? Duh.



And - if you are about to reply with another silly predefined answer
then better don't answer at all, thank you.


[2010-07-25 17:50:44] paj...@php.net

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.






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/bug.php?id=52439


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


Bug #52434 [Bgs]: mysqlnd: host cannot be localhost when connecting to tcp port

2010-07-25 Thread anthon dot pang at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=52434edit=1

 ID:   52434
 User updated by:  anthon dot pang at gmail dot com
 Reported by:  anthon dot pang at gmail dot com
 Summary:  mysqlnd: host cannot be localhost when connecting to
   tcp port
 Status:   Bogus
 Type: Bug
 Package:  MySQL related
 Operating System: Ubuntu 10.04
 PHP Version:  5.3.3

 New Comment:

Ok.  I'll open a Documentation bug for this compat buster.


Previous Comments:

[2010-07-25 18:33:43] johan...@php.net

The patch won't be added as then localhost has two meanings - one time
meaning use the unixdomain socket in the default location and one time
actually resolve localhost and use TCP as it is taught in many places
that localhost in MySQL has the first meaning we keep it there.


[2010-07-25 09:05:29] anthon dot pang at gmail dot com

Seriously?



http://www.php.net/manual/en/ref.pdo-mysql.connection.php gives two
examples:



mysql:host=localhost;port=3307;dbname=testdb

mysql:unix_socket=/tmp/mysql.sock;dbname=testdb



And my DSN (constructed by Zend Framework) follows the first example. 
Where does it say I have to define the unix socket in php.ini if I
intend to connect using the tcp port?



Here's the fix:



--- mysqlnd.c.bak   2010-07-25 02:47:29.0 -0400

+++ mysqlnd.c   2010-07-25 02:49:37.0 -0400

@@ -635,7 +635,7 @@

char * transport = NULL;

int transport_len;

 #ifndef PHP_WIN32

-   if (host_len == sizeof(localhost) - 1 
!strncasecmp(host, localhost, host_len)) {

+   if (!port  host_len == sizeof(localhost) - 1 
!strncasecmp(host, localhost, host_len)) {

DBG_INF_FMT(socket=%s, socket? socket:n/a);

if (!socket) {

socket = /tmp/mysql.sock;


[2010-07-25 06:31:41] dtajchre...@php.net

Tell PHP where your mysql.sock file is via the DSN or
pdo_mysql.default_socket in 

the php.ini file and your error will go away. Your conclusion is way
off. 



http://www.php.net/manual/en/ref.pdo-mysql.connection.php


[2010-07-25 04:42:45] anthon dot pang at gmail dot com

Description:

With PDO_MYSQL, if PHP is linked with mysql client libraries (instead of
mysqlnd), the DSN can contain a host parameter with a hostname, e.g.,
host=localhost.



However, with mysqlnd, the host has to be an ip address, e.g.,
host=127.0.0.1.  This occurs for '--with-mysqli=mysqlnd' or
'--with-pdo-mysql=mysqlnd'.  It appears mysqlnd wants to use a Unix
socket even though the port is explictly specified,



This backward incompatibility surprises users migrating from php 5.2.x
and find their apps suddenly can't connect.



MySQL 5.1.41

Test script:
---
From Zend Framework 1.10.6:



$_isConnected = @mysqli_real_connect(

$this-_connection,

$this-_config['host'],

$this-_config['username'],

$this-_config['password'],

$this-_config['dbname'],

$port

);

Expected result:

Expect it to connect.



Actual result:
--
Warning: PDO::__construct() [pdo.--construct]: [2002] No such file or
directory (trying to connect via unix:///tmp/mysql.sock) in
/var/www/libs/Zend/Db/Adapter/Pdo/Abstract.php on line 129

SQLSTATE[HY000] [2002] No such file or directory






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


Bug #52434 [Bgs]: mysqlnd: host cannot be localhost when connecting to tcp port

2010-07-25 Thread johannes
Edit report at http://bugs.php.net/bug.php?id=52434edit=1

 ID:   52434
 Updated by:   johan...@php.net
 Reported by:  anthon dot pang at gmail dot com
 Summary:  mysqlnd: host cannot be localhost when connecting to
   tcp port
 Status:   Bogus
 Type: Bug
 Package:  MySQL related
 Operating System: Ubuntu 10.04
 PHP Version:  5.3.3

 New Comment:

The patch won't be added as then localhost has two meanings - one time
meaning use the unixdomain socket in the default location and one time
actually resolve localhost and use TCP as it is taught in many places
that localhost in MySQL has the first meaning we keep it there.


Previous Comments:

[2010-07-25 09:05:29] anthon dot pang at gmail dot com

Seriously?



http://www.php.net/manual/en/ref.pdo-mysql.connection.php gives two
examples:



mysql:host=localhost;port=3307;dbname=testdb

mysql:unix_socket=/tmp/mysql.sock;dbname=testdb



And my DSN (constructed by Zend Framework) follows the first example. 
Where does it say I have to define the unix socket in php.ini if I
intend to connect using the tcp port?



Here's the fix:



--- mysqlnd.c.bak   2010-07-25 02:47:29.0 -0400

+++ mysqlnd.c   2010-07-25 02:49:37.0 -0400

@@ -635,7 +635,7 @@

char * transport = NULL;

int transport_len;

 #ifndef PHP_WIN32

-   if (host_len == sizeof(localhost) - 1 
!strncasecmp(host, localhost, host_len)) {

+   if (!port  host_len == sizeof(localhost) - 1 
!strncasecmp(host, localhost, host_len)) {

DBG_INF_FMT(socket=%s, socket? socket:n/a);

if (!socket) {

socket = /tmp/mysql.sock;


[2010-07-25 06:31:41] dtajchre...@php.net

Tell PHP where your mysql.sock file is via the DSN or
pdo_mysql.default_socket in 

the php.ini file and your error will go away. Your conclusion is way
off. 



http://www.php.net/manual/en/ref.pdo-mysql.connection.php


[2010-07-25 04:42:45] anthon dot pang at gmail dot com

Description:

With PDO_MYSQL, if PHP is linked with mysql client libraries (instead of
mysqlnd), the DSN can contain a host parameter with a hostname, e.g.,
host=localhost.



However, with mysqlnd, the host has to be an ip address, e.g.,
host=127.0.0.1.  This occurs for '--with-mysqli=mysqlnd' or
'--with-pdo-mysql=mysqlnd'.  It appears mysqlnd wants to use a Unix
socket even though the port is explictly specified,



This backward incompatibility surprises users migrating from php 5.2.x
and find their apps suddenly can't connect.



MySQL 5.1.41

Test script:
---
From Zend Framework 1.10.6:



$_isConnected = @mysqli_real_connect(

$this-_connection,

$this-_config['host'],

$this-_config['username'],

$this-_config['password'],

$this-_config['dbname'],

$port

);

Expected result:

Expect it to connect.



Actual result:
--
Warning: PDO::__construct() [pdo.--construct]: [2002] No such file or
directory (trying to connect via unix:///tmp/mysql.sock) in
/var/www/libs/Zend/Db/Adapter/Pdo/Abstract.php on line 129

SQLSTATE[HY000] [2002] No such file or directory






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


Bug #52435 [Bgs-Ccd]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread felipe
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Updated by:   fel...@php.net
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
-Status:   Bogus
+Status:   Cancelled
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant



Previous Comments:

[2010-07-25 06:21:01] dh123lh1 at hotmail dot com

Description:

where its supposed to pay off the farmvill Iqtest and tell me my
resultsI got this instead of my million farmville coins, i have done
this Iq test please pay my million coins in facebooks farmville



http://www.quizulous.com/toolbar/newaccount/conduit



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'

Test script:
---
I didnt write this 

Expected result:

you get your client quizloos to have farmville pay my million coins

Actual result:
--
stack trace from the page it brought up rather than my reward



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'






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


Bug #1 [ReO-Ccd]: Apache 1.3b3 + mod_php3 is slow

2010-07-25 Thread felipe
Edit report at http://bugs.php.net/bug.php?id=1edit=1

 ID:   1
 Updated by:   fel...@php.net
 Reported by:  rasmus at lerdorf dot on dot ca
 Summary:  Apache 1.3b3 + mod_php3 is slow
-Status:   Re-Opened
+Status:   Cancelled
 Type: Bug
 Package:  Performance problem
 Operating System: Solaris 2.5.1
 PHP Version:  3.0b3



Previous Comments:

[2010-07-21 17:35:09] ahar...@php.net

Test comment. Sorry about the noise.


[2010-07-21 17:34:17] paj...@php.net

unassigned


[2010-07-21 17:34:01] paj...@php.net

test


[2010-07-21 15:57:07] der...@php.net

test-foo2...@#$@#$


[2010-07-21 15:55:26] der...@php.net

test-#62;foo:@$3423#62;




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/bug.php?id=1


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


Bug #52435 [Ccd-Bgs]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread felipe
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID:   52435
 Updated by:   fel...@php.net
 Reported by:  dh123lh1 at hotmail dot com
 Summary:  the bug has kept me from earning my bonus please fix
   and pay me my 1 million fa
-Status:   Cancelled
+Status:   Bogus
 Type: Bug
 Package:  *General Issues
 Operating System: windows 7 home premium Home thea
 PHP Version:  Irrelevant

 New Comment:

.


Previous Comments:

[2010-07-25 06:21:01] dh123lh1 at hotmail dot com

Description:

where its supposed to pay off the farmvill Iqtest and tell me my
resultsI got this instead of my million farmville coins, i have done
this Iq test please pay my million coins in facebooks farmville



http://www.quizulous.com/toolbar/newaccount/conduit



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'

Test script:
---
I didnt write this 

Expected result:

you get your client quizloos to have farmville pay my million coins

Actual result:
--
stack trace from the page it brought up rather than my reward



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'






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


Bug #1 [Ccd-Bgs]: Apache 1.3b3 + mod_php3 is slow

2010-07-25 Thread felipe
Edit report at http://bugs.php.net/bug.php?id=1edit=1

 ID:   1
 Updated by:   fel...@php.net
 Reported by:  rasmus at lerdorf dot on dot ca
 Summary:  Apache 1.3b3 + mod_php3 is slow
-Status:   Cancelled
+Status:   Bogus
 Type: Bug
 Package:  Performance problem
 Operating System: Solaris 2.5.1
 PHP Version:  3.0b3

 New Comment:

.


Previous Comments:

[2010-07-21 17:35:09] ahar...@php.net

Test comment. Sorry about the noise.


[2010-07-21 17:34:17] paj...@php.net

unassigned


[2010-07-21 17:34:01] paj...@php.net

test


[2010-07-21 15:57:07] der...@php.net

test-foo2...@#$@#$


[2010-07-21 15:55:26] der...@php.net

test-#62;foo:@$3423#62;




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/bug.php?id=1


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


Bug #44942 [Com]: exec() hangs apache

2010-07-25 Thread andy dot hilbig at clubsys dot co dot uk
Edit report at http://bugs.php.net/bug.php?id=44942edit=1

 ID:   44942
 Comment by:   andy dot hilbig at clubsys dot co dot uk
 Reported by:  inqualab1985 at gmail dot com
 Summary:  exec() hangs apache
 Status:   No Feedback
 Type: Bug
 Package:  Program Execution
 Operating System: Windows 2000 SP4
 PHP Version:  5.2.5

 New Comment:

I have been plagued with PHP freezing after a few minutes, days or maybe
weeks. 

I use exec() to link to custom vb.exe

I have searched and searched until today tried the
session_write_close(); before the exec()call and session_start ();
after.



I can now click [Next Day]/[Next Day] as fast as I like and all appears
solid now. Other users have connected at the same time.



So, thank you all very much for the cure.



I have umpteen years programming in machine code and 15 in VB6 with the
Jet engine to Access. All works well with Apache/PHP/VB exes. Do I
really need .Net ???


Previous Comments:

[2009-08-27 10:00:24] listephp at andrioli dot com

I've the same problem too.

I tried the latest snapshot 5.2.11RC2-dev build date: Aug 26 2009
23:42:35 , but it shows up.



Configuration

- Windows 2003 R2

- Apache 2.2.11



Both, exec() running java.exe and system() running .NET program, hang
Apache as described above.


[2009-06-08 16:41:29] alex at bartl dot net

Reproducable with PHP 5.2.9-1 on Windows2003 Server with Apache2.2

Workaround with calling session_write_close() before calling exec()

confirmed working



NOT reproducable with PHP 5.2.1 on Windows 2000 Server with IIS5



anyway, seems to be a duplicate of Bug#44994


[2009-04-07 15:12:50] gouldee at netscape dot com

I am having the same or similar issue:

OS: MS2003

PHP: 5.2.6

APACHE2: 2.2



The bug occurs with an PHP script that has a PHP passthru exec call that
hangs every now and then.  After the first hang occurs then any passthru
call hangs in the same manner.



I believe that the passthru call runs as I am calling a sendmail.exe
process that does send the E-Mail, however, the Browser page hangs after
the E-Mail has been sent by sendmail.exe called via passthru().



There are no PHP or Apache2 errors or warnings.  It seems that the
problem happens when (2) calls to the same .exe happens at the same
time, but, I have no real proof of this, as I can't provide execution
times for each instance of the sendmail.exe running.



This is a serious problem, as all pages that call an .exe process after
the initial hang will hang up as well. I can clear the bug by simply
stopping and restarting the Apache service.



I also note that If I run the page, that hangs up, manually in a Command
Prompt DOS window like:  D:\php page.php there are no hangs and the
process performs correctly even during and after the first showing of
the bug.  So the problem seems to be when PHP does an exec call in
conjunction with Apache, as I said even during the time a hang occurs I
can still exec passthru commands from a command prompt.



I can also run any page that calls PHP as long as the page does not have
any exec or passthru calls in it, and all pages with HTML only runs fine
as well during the hang period.


[2009-02-26 15:14:32] frase at cs dot wisc dot edu

This is happening to me as well, PHP 5.2.8, Apache 2.2.11, Windows 2000
Pro SP4.



However, it only seems to happen when PHP is configured as an Apache
module (php5apache2_2.dll); when I configure it as CGI, it works fine.



I also have anecdotal evidence that it's related somehow to other
sockets being open on the system.  In my case, we have a VB (compiled)
application with an embedded IE control, and also opens the serial port
to communicate with some hardware.  If that hardware is plugged in (and
PHP is loaded as a module), then our scripts hang at 'exec(ping -n 1
somehost)'.  If I unplug the hardware (so the serial port can't be
opened), it works.


[2009-02-17 10:12:38] russell_anam at hotmail dot com

I can indeed confirm that this bug exists in the latest PHP version (PHP
5.2.8). exec() would randomly hang the Apache and the only solution was
to restart the whole server (service restart did not help). I can also
confirm that vlabella's solution INDEED worked for us. Since this
workaround works I think it's safe to say this is indeed a PHP bug that
needs to be fixed ASAP.




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/bug.php?id=44942


-- 
Edit this 

Bug #52435 [Com]: the bug has kept me from earning my bonus please fix and pay me my 1 million fa

2010-07-25 Thread strager dot nds at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=52435edit=1

 ID: 52435
 Comment by: strager dot nds at gmail dot com
 Reported by:dh123lh1 at hotmail dot com
 Summary:the bug has kept me from earning my bonus please fix
 and pay me my 1 million fa
 Status: Bogus
 Type:   Bug
 Package:*General Issues
 Operating System:   windows 7 home premium Home thea
 PHP Version:Irrelevant
 Block user comment: N

 New Comment:

I get this problem too.  It only seems to happen if your IQ is less than
70, though.


Previous Comments:

[2010-07-25 20:59:50] fel...@php.net

.


[2010-07-25 06:21:01] dh123lh1 at hotmail dot com

Description:

where its supposed to pay off the farmvill Iqtest and tell me my
resultsI got this instead of my million farmville coins, i have done
this Iq test please pay my million coins in facebooks farmville



http://www.quizulous.com/toolbar/newaccount/conduit



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'

Test script:
---
I didnt write this 

Expected result:

you get your client quizloos to have farmville pay my million coins

Actual result:
--
stack trace from the page it brought up rather than my reward



mysql_connect() [function.mysql-connect]: Host '74.53.23.135' is blocked
because of many connection errors; unblock with 'mysqladmin flush-hosts'






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


[PHP-BUG] Bug #52441 [NEW]: Arrays misbehaving with __set() and __get()

2010-07-25 Thread bastard dot internets at gmail dot com
From: 
Operating system: WIN
PHP version:  Irrelevant
Package:  Class/Object related
Bug Type: Bug
Bug description:Arrays misbehaving with __set() and __get()

Description:

Mixing __set(), __get(), and protected/private/overloaded properties that
are arrays has unexpected, undocumented, and undesirable results.  A couple
of bugs listed below.  One bug is similar to bug 33941, but the problem
still persists and even more bugs have popped up.

Test script:
---
?php

class A {

protected $test_array = array('key' = 'test');

  

function __get($prop) {

if (!property_exists($this, $prop)) {

$this-$prop = null; // just to create it if it didn't 
exist

}

return $this-$prop;

}



function __set($prop, $val) {

$this-$prop = $val;

}

}



$a = new A();

$a-test_array[] = 'asdf';



?

Expected result:

New key/value 0='asdf' assigned to protected class property array
'$test_array'.  If the property didn't yet exist and overloading is
attempted, just create the new '$test_array' property as an array as
intended.  Working with arrays in this manner should work exactly like with
any other variable type.

Actual result:
--
Depending on how the above test script is slightly tweaked, a few bugs pop
up.  The focus here is on what happens with line $a-test_array[] =
'asdf';





1) If $test_array did *not* previously exist, Notice: Indirect
modification of overloaded property A::$test_array has no effect in
...test.php on line 18.  This *should've* worked fine.



2) If __set() was *not* declared, Notice: Indirect modification of
overloaded property A::$test_array has no effect in ...test.php on line
18.  This *should've* resulted in fatal cannot access protected property
error.



3) If $test_array did *not* previously exist and __get() was *not*
declared, it will work fine.  __get() *should've* never factored in here,
and $test_array *should've* updated even if already declared
private/protected.



4) If __get() was *not* declared, PHP Fatal error:  Cannot access
protected property A::$test_array.   __get() *should've* never factored in
here.  If the '[]' compound operator is what's causing this, then __get()
should return a copy of the array with new or existing index if provided to
be processed through __set() as expected.



5) If $test_array was public, it will work fine, bypassing __get() and
__set() as intended.  No bug here.



6) If __get() was declared to return a reference to the property (ie
function __get($prop){}), it will work fine and bypass __set().  Not a
bug, but this workaround may cause other problems if expecting to process
updates through __set() or wanting just a copy of any other property
returned by __get().

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



Bug #52441 [Com]: Arrays misbehaving with __set() and __get()

2010-07-25 Thread bastard dot internets at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=52441edit=1

 ID: 52441
 Comment by: bastard dot internets at gmail dot com
 Reported by:bastard dot internets at gmail dot com
 Summary:Arrays misbehaving with __set() and __get()
 Status: Open
 Type:   Bug
 Package:Class/Object related
 Operating System:   WIN
 PHP Version:Irrelevant
 Block user comment: N

 New Comment:

Amendment to bug #3: __set() is bypassed completely, and new arrays can
be freely created within objects if not already protected or private. 
Only if directly setting the array itself (ie $a-test_array =
array();) will __set() be called.  But not when doing something like
a$-test_array[] = 'asdf';


Previous Comments:

[2010-07-26 01:19:24] bastard dot internets at gmail dot com

Description:

Mixing __set(), __get(), and protected/private/overloaded properties
that are arrays has unexpected, undocumented, and undesirable results. 
A couple of bugs listed below.  One bug is similar to bug 33941, but the
problem still persists and even more bugs have popped up.

Test script:
---
?php

class A {

protected $test_array = array('key' = 'test');

  

function __get($prop) {

if (!property_exists($this, $prop)) {

$this-$prop = null; // just to create it if it didn't 
exist

}

return $this-$prop;

}



function __set($prop, $val) {

$this-$prop = $val;

}

}



$a = new A();

$a-test_array[] = 'asdf';



?

Expected result:

New key/value 0='asdf' assigned to protected class property array
'$test_array'.  If the property didn't yet exist and overloading is
attempted, just create the new '$test_array' property as an array as
intended.  Working with arrays in this manner should work exactly like
with any other variable type.

Actual result:
--
Depending on how the above test script is slightly tweaked, a few bugs
pop up.  The focus here is on what happens with line $a-test_array[] =
'asdf';





1) If $test_array did *not* previously exist, Notice: Indirect
modification of overloaded property A::$test_array has no effect in
...test.php on line 18.  This *should've* worked fine.



2) If __set() was *not* declared, Notice: Indirect modification of
overloaded property A::$test_array has no effect in ...test.php on line
18.  This *should've* resulted in fatal cannot access protected
property error.



3) If $test_array did *not* previously exist and __get() was *not*
declared, it will work fine.  __get() *should've* never factored in
here, and $test_array *should've* updated even if already declared
private/protected.



4) If __get() was *not* declared, PHP Fatal error:  Cannot access
protected property A::$test_array.   __get() *should've* never factored
in here.  If the '[]' compound operator is what's causing this, then
__get() should return a copy of the array with new or existing index if
provided to be processed through __set() as expected.



5) If $test_array was public, it will work fine, bypassing __get() and
__set() as intended.  No bug here.



6) If __get() was declared to return a reference to the property (ie
function __get($prop){}), it will work fine and bypass __set().  Not a
bug, but this workaround may cause other problems if expecting to
process updates through __set() or wanting just a copy of any other
property returned by __get().






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


Bug #52441 [Com]: Arrays misbehaving with __set() and __get()

2010-07-25 Thread bastard dot internets at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=52441edit=1

 ID: 52441
 Comment by: bastard dot internets at gmail dot com
 Reported by:bastard dot internets at gmail dot com
 Summary:Arrays misbehaving with __set() and __get()
 Status: Open
 Type:   Bug
 Package:Class/Object related
 Operating System:   WIN
 PHP Version:Irrelevant
 Block user comment: N

 New Comment:

Der, that last comment was meant to be Amendment to Result #3.  Ignore
that auto-linked reference to bug #3


Previous Comments:

[2010-07-26 01:36:21] bastard dot internets at gmail dot com

Amendment to bug #3: __set() is bypassed completely, and new arrays can
be freely created within objects if not already protected or private. 
Only if directly setting the array itself (ie $a-test_array =
array();) will __set() be called.  But not when doing something like
a$-test_array[] = 'asdf';


[2010-07-26 01:19:24] bastard dot internets at gmail dot com

Description:

Mixing __set(), __get(), and protected/private/overloaded properties
that are arrays has unexpected, undocumented, and undesirable results. 
A couple of bugs listed below.  One bug is similar to bug 33941, but the
problem still persists and even more bugs have popped up.

Test script:
---
?php

class A {

protected $test_array = array('key' = 'test');

  

function __get($prop) {

if (!property_exists($this, $prop)) {

$this-$prop = null; // just to create it if it didn't 
exist

}

return $this-$prop;

}



function __set($prop, $val) {

$this-$prop = $val;

}

}



$a = new A();

$a-test_array[] = 'asdf';



?

Expected result:

New key/value 0='asdf' assigned to protected class property array
'$test_array'.  If the property didn't yet exist and overloading is
attempted, just create the new '$test_array' property as an array as
intended.  Working with arrays in this manner should work exactly like
with any other variable type.

Actual result:
--
Depending on how the above test script is slightly tweaked, a few bugs
pop up.  The focus here is on what happens with line $a-test_array[] =
'asdf';





1) If $test_array did *not* previously exist, Notice: Indirect
modification of overloaded property A::$test_array has no effect in
...test.php on line 18.  This *should've* worked fine.



2) If __set() was *not* declared, Notice: Indirect modification of
overloaded property A::$test_array has no effect in ...test.php on line
18.  This *should've* resulted in fatal cannot access protected
property error.



3) If $test_array did *not* previously exist and __get() was *not*
declared, it will work fine.  __get() *should've* never factored in
here, and $test_array *should've* updated even if already declared
private/protected.



4) If __get() was *not* declared, PHP Fatal error:  Cannot access
protected property A::$test_array.   __get() *should've* never factored
in here.  If the '[]' compound operator is what's causing this, then
__get() should return a copy of the array with new or existing index if
provided to be processed through __set() as expected.



5) If $test_array was public, it will work fine, bypassing __get() and
__set() as intended.  No bug here.



6) If __get() was declared to return a reference to the property (ie
function __get($prop){}), it will work fine and bypass __set().  Not a
bug, but this workaround may cause other problems if expecting to
process updates through __set() or wanting just a copy of any other
property returned by __get().






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


Bug #52441 [Opn]: Arrays misbehaving with __set() and __get()

2010-07-25 Thread bastard dot internets at gmail dot com
Edit report at http://bugs.php.net/bug.php?id=52441edit=1

 ID: 52441
 User updated by:bastard dot internets at gmail dot com
 Reported by:bastard dot internets at gmail dot com
 Summary:Arrays misbehaving with __set() and __get()
 Status: Open
 Type:   Bug
 Package:Class/Object related
 Operating System:   WIN
-PHP Version:Irrelevant
+PHP Version:5.3.3 and 5.3.2
 Block user comment: N

 New Comment:

PHP Version: These bugs are found in 5.3.3 and 5.3.2.  Unknown status in
5.2.


Previous Comments:

[2010-07-26 01:39:17] bastard dot internets at gmail dot com

Der, that last comment was meant to be Amendment to Result #3.  Ignore
that auto-linked reference to bug #3


[2010-07-26 01:36:21] bastard dot internets at gmail dot com

Amendment to bug #3: __set() is bypassed completely, and new arrays can
be freely created within objects if not already protected or private. 
Only if directly setting the array itself (ie $a-test_array =
array();) will __set() be called.  But not when doing something like
a$-test_array[] = 'asdf';


[2010-07-26 01:19:24] bastard dot internets at gmail dot com

Description:

Mixing __set(), __get(), and protected/private/overloaded properties
that are arrays has unexpected, undocumented, and undesirable results. 
A couple of bugs listed below.  One bug is similar to bug 33941, but the
problem still persists and even more bugs have popped up.

Test script:
---
?php

class A {

protected $test_array = array('key' = 'test');

  

function __get($prop) {

if (!property_exists($this, $prop)) {

$this-$prop = null; // just to create it if it didn't 
exist

}

return $this-$prop;

}



function __set($prop, $val) {

$this-$prop = $val;

}

}



$a = new A();

$a-test_array[] = 'asdf';



?

Expected result:

New key/value 0='asdf' assigned to protected class property array
'$test_array'.  If the property didn't yet exist and overloading is
attempted, just create the new '$test_array' property as an array as
intended.  Working with arrays in this manner should work exactly like
with any other variable type.

Actual result:
--
Depending on how the above test script is slightly tweaked, a few bugs
pop up.  The focus here is on what happens with line $a-test_array[] =
'asdf';





1) If $test_array did *not* previously exist, Notice: Indirect
modification of overloaded property A::$test_array has no effect in
...test.php on line 18.  This *should've* worked fine.



2) If __set() was *not* declared, Notice: Indirect modification of
overloaded property A::$test_array has no effect in ...test.php on line
18.  This *should've* resulted in fatal cannot access protected
property error.



3) If $test_array did *not* previously exist and __get() was *not*
declared, it will work fine.  __get() *should've* never factored in
here, and $test_array *should've* updated even if already declared
private/protected.



4) If __get() was *not* declared, PHP Fatal error:  Cannot access
protected property A::$test_array.   __get() *should've* never factored
in here.  If the '[]' compound operator is what's causing this, then
__get() should return a copy of the array with new or existing index if
provided to be processed through __set() as expected.



5) If $test_array was public, it will work fine, bypassing __get() and
__set() as intended.  No bug here.



6) If __get() was declared to return a reference to the property (ie
function __get($prop){}), it will work fine and bypass __set().  Not a
bug, but this workaround may cause other problems if expecting to
process updates through __set() or wanting just a copy of any other
property returned by __get().






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


Bug #52438 [Opn-Bgs]: Parser error on a simple example

2010-07-25 Thread scottmac
Edit report at http://bugs.php.net/bug.php?id=52438edit=1

 ID: 52438
 Updated by: scott...@php.net
 Reported by:dagdamor10 at mail dot ru
 Summary:Parser error on a simple example
-Status: Open
+Status: Bogus
 Type:   Bug
 Package:Scripting Engine problem
 Operating System:   Windows
 PHP Version:5.2.14
 Block user comment: N

 New Comment:

It's always been ?php\w that has been required for lexer.


Previous Comments:

[2010-07-25 16:02:05] dagdamor10 at mail dot ru

Description:

My framework (http://www.phpc.ru) uses automatic code generation, and
when I was fine-tuning it, I discovered a weird error in the PHP parser.

Test script:
---
?php



function test() {?This is a test.?php}



?

Expected result:

Empty screen (since the function is never called)

Actual result:
--
Parse error: syntax error, unexpected $end in index.php on line 6





If you add a space character between ?php and }, it works just
fine.



I simply used a workaround, but maybe this report will be useful for
you.






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


Bug #1 [Bgs]: Apache 1.3b3 + mod_php3 is slow

2010-07-25 Thread felipe
Edit report at http://bugs.php.net/bug.php?id=1edit=1

 ID: 1
 Updated by: fel...@php.net
 Reported by:rasmus at lerdorf dot on dot ca
 Summary:Apache 1.3b3 + mod_php3 is slow
 Status: Bogus
 Type:   Bug
 Package:Performance problem
 Operating System:   Solaris 2.5.1
 PHP Version:3.0b3
-Block user comment: N
+Block user comment: Y

 New Comment:

testing


Previous Comments:

[2010-07-25 21:00:15] fel...@php.net

.


[2010-07-21 17:35:09] ahar...@php.net

Test comment. Sorry about the noise.


[2010-07-21 17:34:17] paj...@php.net

unassigned


[2010-07-21 17:34:01] paj...@php.net

test


[2010-07-21 15:57:07] der...@php.net

test-foo2...@#$@#$




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/bug.php?id=1


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


Bug #1 [Bgs]: Apache 1.3b3 + mod_php3 is slow

2010-07-25 Thread felipe
Edit report at http://bugs.php.net/bug.php?id=1edit=1

 ID: 1
 Updated by: fel...@php.net
 Reported by:rasmus at lerdorf dot on dot ca
 Summary:Apache 1.3b3 + mod_php3 is slow
 Status: Bogus
 Type:   Bug
 Package:Performance problem
 Operating System:   Solaris 2.5.1
 PHP Version:3.0b3
 Block user comment: Y

 New Comment:

test


Previous Comments:

[2010-07-26 03:06:49] fel...@php.net

testing


[2010-07-25 21:00:15] fel...@php.net

.


[2010-07-21 17:35:09] ahar...@php.net

Test comment. Sorry about the noise.


[2010-07-21 17:34:17] paj...@php.net

unassigned


[2010-07-21 17:34:01] paj...@php.net

test




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/bug.php?id=1


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


Bug #52433 [Bgs]: Call to undefined method mysqli::poll()

2010-07-25 Thread admin at webdesignforall dot net
Edit report at http://bugs.php.net/bug.php?id=52433edit=1

 ID: 52433
 User updated by:admin at webdesignforall dot net
 Reported by:admin at webdesignforall dot net
 Summary:Call to undefined method mysqli::poll()
 Status: Bogus
 Type:   Bug
 Package:MySQLi related
 Operating System:   Debian 5
 PHP Version:5.3.3
 Block user comment: N

 New Comment:

It is compiled with mysqlnd here is the configure line.





Configure Command =  './configure'  '--prefix=/custom/php-5.3.3'
'--with-

mysqli=mysqlnd' '--with-pdo-mysql=mysqlnd'





Like I said mysqli_poll works fine just mysqli::poll doesn't, so there's


something wrong with the mysqli class.


Previous Comments:

[2010-07-25 18:34:58] johan...@php.net

MySQLi asynchronous queries only exist if PHP was compiled using mysqlnd
(--with-mysqli=myslqnd)


[2010-07-25 02:32:43] admin at webdesignforall dot net

Description:

The static method mysqli::poll doesn't exist. Using it creates a Fatal
error: Call 

to undefined method mysqli::poll() .



mysqli_poll works fine.

Test script:
---
?php

$link1 = new mysqli(localhost,root,,dba);

$link1-query(SELECT 'test', MYSQLI_ASYNC);

$done=false;

do

{

  $links = $errors = $reject = array();

  $links[] = $errors[] = $reject[] = $link1;

  if (!mysqli::poll($links, $errors, $reject, 1)) {

continue;

}

if ($result = $links[0]-reap_async_query()) {

$done=true;

}

}

while(!$done);



Expected result:

No output.

Actual result:
--
Fatal error: Call to undefined method mysqli::poll() 






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