Req #26411 [Opn->Wfx]: while {} else {}

2012-08-21 Thread laruence
Edit report at https://bugs.php.net/bug.php?id=26411&edit=1

 ID: 26411
 Updated by: larue...@php.net
 Reported by:php at bellytime dot com
 Summary:while {} else {}
-Status: Open
+Status: Wont fix
 Type:   Feature/Change Request
 Package:Scripting Engine problem
 Operating System:   *
 PHP Version:*
 Block user comment: N
 Private report: N

 New Comment:

no such syntax in other languages.


Previous Comments:

[2012-08-21 17:38:24] bensor987 at neuf dot fr

Why don't you go a little bit further ?

while ( $row = mysql_fetch_assoc( $result ) ){

} else for ( $i = 0; $i < $cpt; $i++ ) {

} else if ( $dude ) {

} else {

}


[2012-04-26 02:13:36] ma-martin at hotmail dot de

Hey, i was also looking for some while {} else {} feature...
but i think it could be difficult to implement such a function in php.
Because the else{} event would start after the while{}-loop ends -> everytime 
after the last result!
think about it!


[2012-01-25 12:16:57] hawkyhawk14 at gmail dot com

This is a great idea. I am currently needing something like this, but however 
got 
around it using flags and making the flag true in the while. It would be alot 
more 
convenient if there was an else!

Please add this feature!!!


[2011-12-06 16:31:22] absimu at hotmail dot com

I agree. I think a while () else () will make things easier. I was researching 
and 
found out that it doesnt exist yet. 


while($row = mysqli_fetch_assoc($result)) { }

with al else I would fix it.. I am new in PHP,. I will try to find something to 
fix it. but if the while else is release in a new version that would be nice.


[2011-02-18 01:14:34] ijrbiz at gmail dot com

Highly agreed, this request would be very practical for improved coding 
structure and 
follows logical language syntax nicely.

function remove_items (&$arr, $needle) {
while ($key = array_search($needle, $arr)) {
unset( $arr[$key] );
} else return false; // No items present
return true; // Item(s) removed
}




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

https://bugs.php.net/bug.php?id=26411


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


Bug #62884 [Opn]: parse_ini_file() results changed in 5.3.15

2012-08-21 Thread laruence
Edit report at https://bugs.php.net/bug.php?id=62884&edit=1

 ID: 62884
 Updated by: larue...@php.net
 Reported by:fidian at rumkin dot com
 Summary:parse_ini_file() results changed in 5.3.15
 Status: Open
 Type:   Bug
 Package:Unknown/Other Function
 Operating System:   Ubuntu Linus 12.04
 PHP Version:5.3Git-2012-08-21 (Git)
-Assigned To:
+Assigned To:pierrick
 Block user comment: N
 Private report: N

 New Comment:

Pierrick,  do you have time to look into this?  thanks


Previous Comments:

[2012-08-21 23:50:18] fidian at rumkin dot com

For clarification, what Microsoft says is

If the string associated with lpKeyName is enclosed in single or double 
quotation marks, the marks are discarded when the GetPrivateProfileString 
function retrieves the string.

This leads me to believe that it merely checks if the first and last character 
match and if they are a " or ' and then would remove both the first and last 
character.


[2012-08-21 23:48:41] fidian at rumkin dot com

Description:

Given an INI file that looks like this

ini = "a"b"

and when you use parse_ini_file with INI_SCANNER_RAW, PHP used to return this 
as 
array('ini' => 'a"b') and now returns it as array('ini' => 'ab"').  This does 
not appear to match with Microsoft's GetPrivateProfileString 
(http://msdn.microsoft.com/en-us/library/ms724353(VS.85).aspx) where they say 
that values which are quoted with either single or double quotes are simply 
unquoted.  My expected behavior would be to mirror the Microsoft parser, 
especially when in raw mode.

Note:  I am not talking about changing INI_SCANNER_NORMAL, just the raw mode so 
I can get the unparsed values.

According to git-bisect, commit 4e6f27f4db6121e67f17906b27cc829120738b71 is the 
culprit, but I suspect that the fix for bug 51094 is really to blame.

Test script:
---
 'a"b',
)


Actual result:
--
array (
  'ini' => 'ab"',
)







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


Bug #62885 [Opn->Csd]: mysqli_poll - Segmentation fault

2012-08-21 Thread laruence
Edit report at https://bugs.php.net/bug.php?id=62885&edit=1

 ID: 62885
 Updated by: larue...@php.net
 Reported by:mateusz dot goik at aliantsoft dot pl
 Summary:mysqli_poll - Segmentation fault
-Status: Open
+Status: Closed
 Type:   Bug
 Package:MySQLi related
 Operating System:   Backtrack 5r2
 PHP Version:5.4Git-2012-08-21 (snap)
-Assigned To:
+Assigned To:laruence
 Block user comment: N
 Private report: N

 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/.

 For Windows:

http://windows.php.net/snapshots/
 
Thank you for the report, and for helping us make PHP better.

hmm, simple fix.. committed


Previous Comments:

[2012-08-22 05:39:13] larue...@php.net

Automatic comment on behalf of laruence
Revision: 
http://git.php.net/?p=php-src.git;a=commit;h=e5bdd2c0eeab50dc1f863dae9a32d3857ece6a79
Log: Fixed bug #62885 (mysqli_poll - Segmentation fault)


[2012-08-21 23:58:48] mateusz dot goik at aliantsoft dot pl

Description:

mysqli_poll - Segmentation fault

PHP 5.4.7-dev (cli) (built: Aug 22 2012 00:48:06) 

Program received signal SIGSEGV, Segmentation fault.
0x009051a1 in mysqlnd_stream_array_check_for_readiness (conn_array=0x0) 
at /home/test/php-trunk-201208212130/ext/mysqlnd/mysqlnd.c:1113
1113while (*p) {

Test script:
---


Actual result:
--
#0  0x009051a1 in mysqlnd_stream_array_check_for_readiness 
(conn_array=0x0) at /home/test/php-trunk-201208212130/ext/mysqlnd/mysqlnd.c:1113
#1  0x00905533 in _mysqlnd_poll (r_array=0x0, e_array=0x0, 
dont_poll=0x7fff82480080, sec=0, usec=0, desc_num=0x7fff8248006c) at 
/home/test/php-trunk-201208212130/ext/mysqlnd/mysqlnd.c:1223
#2  0x006e6012 in zif_mysqli_poll (ht=4, return_value=0x7fb217b8b370, 
return_value_ptr=0x0, this_ptr=0x0, return_value_used=1) at 
/home/test/php-trunk-201208212130/ext/mysqli/mysqli_nonapi.c:791
#3  0x009fe45c in zend_do_fcall_common_helper_SPEC 
(execute_data=0x7fb217b57060) at 
/home/test/php-trunk-201208212130/Zend/zend_vm_execute.h:642
#4  0x00a05075 in ZEND_DO_FCALL_SPEC_CONST_HANDLER 
(execute_data=0x7fb217b57060) at 
/home/test/php-trunk-201208212130/Zend/zend_vm_execute.h:2219
#5  0x009fcefd in execute (op_array=0x7fb217b8ac50) at 
/home/test/php-trunk-201208212130/Zend/zend_vm_execute.h:410
#6  0x009c38e3 in zend_execute_scripts (type=8, retval=0x0, 
file_count=3) at /home/test/php-trunk-201208212130/Zend/zend.c:1286
#7  0x009413a4 in php_execute_script (primary_file=0x7fff82483940) at 
/home/test/php-trunk-201208212130/main/main.c:2473
#8  0x00af847d in do_cli (argc=2, argv=0x7fff82483cf8) at 
/home/test/php-trunk-201208212130/sapi/cli/php_cli.c:988
#9  0x00af92a3 in main (argc=2, argv=0x7fff82483cf8) at 
/home/test/php-trunk-201208212130/sapi/cli/php_cli.c:1364







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


Bug #62881 [Com]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread reeze dot xia at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=62881&edit=1

 ID: 62881
 Comment by: reeze dot xia at gmail dot com
 Reported by:reeze dot xia at gmail dot com
 Summary:posix_getpwnam("") && posix_getgrnam("") didn't
 return false on Mac OSX 10.8
 Status: Wont fix
 Type:   Bug
 Package:POSIX related
 Operating System:   Mac OSX 10.8
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

NO, I don't mean that. PHP isn't always running on lastest OS.
It just a conditional workaround for buggy api.

Since there are not that much application running on OSX.
I'm ok if you guys think we didn't fix that.


Previous Comments:

[2012-08-22 04:57:57] larue...@php.net

you think we should fix this, then after apple fixed their bug, we remove this 
fix 
then?


[2012-08-22 04:10:58] reeze dot xia at gmail dot com

OooK... by hacking /etc/passwd  hmmm. $ useradd didn't allow that.

so technically uid could be -1, etc heh.

anyway, there always trade off, I prefer it get fixed.


[2012-08-22 03:50:53] ahar...@php.net

Yeah, I had to edit /etc/passwd directly to do it, but it's possible, and once 
created, the account works normally on Linux: http://i.imgur.com/PI3zt.png


[2012-08-22 03:45:25] reeze dot xia at gmail dot com

Hi, aharvey
  how did you made it? by a tricky way?. :)


[2012-08-22 03:43:45] larue...@php.net

it's no need:

1. first it's a knew bug of apple, apple will fix that

2. as you said, you can create a group with empty string in ubuntu.

we have no reason to introduce such a temporary fix




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

https://bugs.php.net/bug.php?id=62881


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


Bug #62881 [Wfx]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread laruence
Edit report at https://bugs.php.net/bug.php?id=62881&edit=1

 ID: 62881
 Updated by: larue...@php.net
 Reported by:reeze dot xia at gmail dot com
 Summary:posix_getpwnam("") && posix_getgrnam("") didn't
 return false on Mac OSX 10.8
 Status: Wont fix
 Type:   Bug
 Package:POSIX related
 Operating System:   Mac OSX 10.8
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

you think we should fix this, then after apple fixed their bug, we remove this 
fix 
then?


Previous Comments:

[2012-08-22 04:10:58] reeze dot xia at gmail dot com

OooK... by hacking /etc/passwd  hmmm. $ useradd didn't allow that.

so technically uid could be -1, etc heh.

anyway, there always trade off, I prefer it get fixed.


[2012-08-22 03:50:53] ahar...@php.net

Yeah, I had to edit /etc/passwd directly to do it, but it's possible, and once 
created, the account works normally on Linux: http://i.imgur.com/PI3zt.png


[2012-08-22 03:45:25] reeze dot xia at gmail dot com

Hi, aharvey
  how did you made it? by a tricky way?. :)


[2012-08-22 03:43:45] larue...@php.net

it's no need:

1. first it's a knew bug of apple, apple will fix that

2. as you said, you can create a group with empty string in ubuntu.

we have no reason to introduce such a temporary fix


[2012-08-22 03:18:07] ahar...@php.net

To reiterate what I said on GitHub: I think we could put a workaround in just 
for those OS X versions behind an appropriate #if guard (blank user and group 
names are valid in at least some POSIX OSes, so we don't want to hardcode the 
behaviour for posix_getgrnam('')), but it's probably not worth the code clutter 
in the grand scheme of things.




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

https://bugs.php.net/bug.php?id=62881


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


Bug #62881 [Com]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread reeze dot xia at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=62881&edit=1

 ID: 62881
 Comment by: reeze dot xia at gmail dot com
 Reported by:reeze dot xia at gmail dot com
 Summary:posix_getpwnam("") && posix_getgrnam("") didn't
 return false on Mac OSX 10.8
 Status: Wont fix
 Type:   Bug
 Package:POSIX related
 Operating System:   Mac OSX 10.8
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

OooK... by hacking /etc/passwd  hmmm. $ useradd didn't allow that.

so technically uid could be -1, etc heh.

anyway, there always trade off, I prefer it get fixed.


Previous Comments:

[2012-08-22 03:50:53] ahar...@php.net

Yeah, I had to edit /etc/passwd directly to do it, but it's possible, and once 
created, the account works normally on Linux: http://i.imgur.com/PI3zt.png


[2012-08-22 03:45:25] reeze dot xia at gmail dot com

Hi, aharvey
  how did you made it? by a tricky way?. :)


[2012-08-22 03:43:45] larue...@php.net

it's no need:

1. first it's a knew bug of apple, apple will fix that

2. as you said, you can create a group with empty string in ubuntu.

we have no reason to introduce such a temporary fix


[2012-08-22 03:18:07] ahar...@php.net

To reiterate what I said on GitHub: I think we could put a workaround in just 
for those OS X versions behind an appropriate #if guard (blank user and group 
names are valid in at least some POSIX OSes, so we don't want to hardcode the 
behaviour for posix_getgrnam('')), but it's probably not worth the code clutter 
in the grand scheme of things.


[2012-08-22 03:02:37] larue...@php.net

same comment copied from the pr:

we don't fix bug doesn't belong to php
Linux man page of posix_getpwnam doesn't specific the situation about empty 
string
Posix functions are buggy in mac os. so, won't fix for this, leave it to apple .
btw:

after a quick google, seems you have file a bug to apple, then file another bug 
to ruby..

and the ruby guy told you the same thing I told.

why you still think it should be fixed in php self?




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

https://bugs.php.net/bug.php?id=62881


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


Bug #62881 [Wfx]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread aharvey
Edit report at https://bugs.php.net/bug.php?id=62881&edit=1

 ID: 62881
 Updated by: ahar...@php.net
 Reported by:reeze dot xia at gmail dot com
 Summary:posix_getpwnam("") && posix_getgrnam("") didn't
 return false on Mac OSX 10.8
 Status: Wont fix
 Type:   Bug
 Package:POSIX related
 Operating System:   Mac OSX 10.8
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

Yeah, I had to edit /etc/passwd directly to do it, but it's possible, and once 
created, the account works normally on Linux: http://i.imgur.com/PI3zt.png


Previous Comments:

[2012-08-22 03:45:25] reeze dot xia at gmail dot com

Hi, aharvey
  how did you made it? by a tricky way?. :)


[2012-08-22 03:43:45] larue...@php.net

it's no need:

1. first it's a knew bug of apple, apple will fix that

2. as you said, you can create a group with empty string in ubuntu.

we have no reason to introduce such a temporary fix


[2012-08-22 03:18:07] ahar...@php.net

To reiterate what I said on GitHub: I think we could put a workaround in just 
for those OS X versions behind an appropriate #if guard (blank user and group 
names are valid in at least some POSIX OSes, so we don't want to hardcode the 
behaviour for posix_getgrnam('')), but it's probably not worth the code clutter 
in the grand scheme of things.


[2012-08-22 03:02:37] larue...@php.net

same comment copied from the pr:

we don't fix bug doesn't belong to php
Linux man page of posix_getpwnam doesn't specific the situation about empty 
string
Posix functions are buggy in mac os. so, won't fix for this, leave it to apple .
btw:

after a quick google, seems you have file a bug to apple, then file another bug 
to ruby..

and the ruby guy told you the same thing I told.

why you still think it should be fixed in php self?


[2012-08-21 17:06:22] reeze dot xia at gmail dot com

Hi,
  I'v sent a pull request for this bug:

https://github.com/php/php-src/pull/176


thanks




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

https://bugs.php.net/bug.php?id=62881


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


Bug #62881 [Com]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread reeze dot xia at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=62881&edit=1

 ID: 62881
 Comment by: reeze dot xia at gmail dot com
 Reported by:reeze dot xia at gmail dot com
 Summary:posix_getpwnam("") && posix_getgrnam("") didn't
 return false on Mac OSX 10.8
 Status: Wont fix
 Type:   Bug
 Package:POSIX related
 Operating System:   Mac OSX 10.8
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

Hi, aharvey
  how did you made it? by a tricky way?. :)


Previous Comments:

[2012-08-22 03:43:45] larue...@php.net

it's no need:

1. first it's a knew bug of apple, apple will fix that

2. as you said, you can create a group with empty string in ubuntu.

we have no reason to introduce such a temporary fix


[2012-08-22 03:18:07] ahar...@php.net

To reiterate what I said on GitHub: I think we could put a workaround in just 
for those OS X versions behind an appropriate #if guard (blank user and group 
names are valid in at least some POSIX OSes, so we don't want to hardcode the 
behaviour for posix_getgrnam('')), but it's probably not worth the code clutter 
in the grand scheme of things.


[2012-08-22 03:02:37] larue...@php.net

same comment copied from the pr:

we don't fix bug doesn't belong to php
Linux man page of posix_getpwnam doesn't specific the situation about empty 
string
Posix functions are buggy in mac os. so, won't fix for this, leave it to apple .
btw:

after a quick google, seems you have file a bug to apple, then file another bug 
to ruby..

and the ruby guy told you the same thing I told.

why you still think it should be fixed in php self?


[2012-08-21 17:06:22] reeze dot xia at gmail dot com

Hi,
  I'v sent a pull request for this bug:

https://github.com/php/php-src/pull/176


thanks


[2012-08-21 16:54:16] reeze dot xia at gmail dot com

Description:

In Mac OS X 10.8 mountain lion, getpwnam() && getgrnam() didn't return NULL
when empty string supplied. this is a bug of 10.8.0

since uid 0 an gid 0 most belongs to root, this might have security issue.

and this breaks these test cases:
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam.phpt]
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam_basic.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam_basic.phpt]

here is reproducible code from: Andreas Fink :
#include 
#include 
#include 
#include 
#include 

#define MAYBE_NULL_STRING(a)(a ? a : "(NULL)")

extern int errno;

int main(int argc, char *argv[])
{
errno = 0;
struct passwd *pwdstruct = getpwnam("");
printf("errno = %d\n",errno);
if(pwdstruct == NULL)
{
printf("pwdstruct == NULL\n");
exit(0);
}

printf("pw_name: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_name));
printf("pw_passwd: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_passwd));
printf("pw_uid: %d\n",pwdstruct->pw_uid);
printf("pw_gid: %d\n",pwdstruct->pw_gid);
}


produces

$ ./a.out 
errno = 0
pw_name: 
pw_passwd: 
pw_uid: 0
pw_gid: 0


Test script:
---

  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["uid"]=>
  int(0)
  ["gid"]=>
  int(0)
  ["gecos"]=>
  string(0) ""
  ["dir"]=>
  string(0) ""
  ["shell"]=>
  string(0) ""
}
array(4) {
  ["name"]=>
  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["members"]=>
  array(0) {
  }
  ["gid"]=>
  int(0)
}






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


Bug #62881 [Wfx]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread laruence
Edit report at https://bugs.php.net/bug.php?id=62881&edit=1

 ID: 62881
 Updated by: larue...@php.net
 Reported by:reeze dot xia at gmail dot com
 Summary:posix_getpwnam("") && posix_getgrnam("") didn't
 return false on Mac OSX 10.8
 Status: Wont fix
 Type:   Bug
 Package:POSIX related
 Operating System:   Mac OSX 10.8
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

it's no need:

1. first it's a knew bug of apple, apple will fix that

2. as you said, you can create a group with empty string in ubuntu.

we have no reason to introduce such a temporary fix


Previous Comments:

[2012-08-22 03:18:07] ahar...@php.net

To reiterate what I said on GitHub: I think we could put a workaround in just 
for those OS X versions behind an appropriate #if guard (blank user and group 
names are valid in at least some POSIX OSes, so we don't want to hardcode the 
behaviour for posix_getgrnam('')), but it's probably not worth the code clutter 
in the grand scheme of things.


[2012-08-22 03:02:37] larue...@php.net

same comment copied from the pr:

we don't fix bug doesn't belong to php
Linux man page of posix_getpwnam doesn't specific the situation about empty 
string
Posix functions are buggy in mac os. so, won't fix for this, leave it to apple .
btw:

after a quick google, seems you have file a bug to apple, then file another bug 
to ruby..

and the ruby guy told you the same thing I told.

why you still think it should be fixed in php self?


[2012-08-21 17:06:22] reeze dot xia at gmail dot com

Hi,
  I'v sent a pull request for this bug:

https://github.com/php/php-src/pull/176


thanks


[2012-08-21 16:54:16] reeze dot xia at gmail dot com

Description:

In Mac OS X 10.8 mountain lion, getpwnam() && getgrnam() didn't return NULL
when empty string supplied. this is a bug of 10.8.0

since uid 0 an gid 0 most belongs to root, this might have security issue.

and this breaks these test cases:
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam.phpt]
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam_basic.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam_basic.phpt]

here is reproducible code from: Andreas Fink :
#include 
#include 
#include 
#include 
#include 

#define MAYBE_NULL_STRING(a)(a ? a : "(NULL)")

extern int errno;

int main(int argc, char *argv[])
{
errno = 0;
struct passwd *pwdstruct = getpwnam("");
printf("errno = %d\n",errno);
if(pwdstruct == NULL)
{
printf("pwdstruct == NULL\n");
exit(0);
}

printf("pw_name: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_name));
printf("pw_passwd: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_passwd));
printf("pw_uid: %d\n",pwdstruct->pw_uid);
printf("pw_gid: %d\n",pwdstruct->pw_gid);
}


produces

$ ./a.out 
errno = 0
pw_name: 
pw_passwd: 
pw_uid: 0
pw_gid: 0


Test script:
---

  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["uid"]=>
  int(0)
  ["gid"]=>
  int(0)
  ["gecos"]=>
  string(0) ""
  ["dir"]=>
  string(0) ""
  ["shell"]=>
  string(0) ""
}
array(4) {
  ["name"]=>
  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["members"]=>
  array(0) {
  }
  ["gid"]=>
  int(0)
}






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


Bug #62881 [Wfx]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread aharvey
Edit report at https://bugs.php.net/bug.php?id=62881&edit=1

 ID: 62881
 Updated by: ahar...@php.net
 Reported by:reeze dot xia at gmail dot com
 Summary:posix_getpwnam("") && posix_getgrnam("") didn't
 return false on Mac OSX 10.8
 Status: Wont fix
 Type:   Bug
 Package:POSIX related
 Operating System:   Mac OSX 10.8
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

To reiterate what I said on GitHub: I think we could put a workaround in just 
for those OS X versions behind an appropriate #if guard (blank user and group 
names are valid in at least some POSIX OSes, so we don't want to hardcode the 
behaviour for posix_getgrnam('')), but it's probably not worth the code clutter 
in the grand scheme of things.


Previous Comments:

[2012-08-22 03:02:37] larue...@php.net

same comment copied from the pr:

we don't fix bug doesn't belong to php
Linux man page of posix_getpwnam doesn't specific the situation about empty 
string
Posix functions are buggy in mac os. so, won't fix for this, leave it to apple .
btw:

after a quick google, seems you have file a bug to apple, then file another bug 
to ruby..

and the ruby guy told you the same thing I told.

why you still think it should be fixed in php self?


[2012-08-21 17:06:22] reeze dot xia at gmail dot com

Hi,
  I'v sent a pull request for this bug:

https://github.com/php/php-src/pull/176


thanks


[2012-08-21 16:54:16] reeze dot xia at gmail dot com

Description:

In Mac OS X 10.8 mountain lion, getpwnam() && getgrnam() didn't return NULL
when empty string supplied. this is a bug of 10.8.0

since uid 0 an gid 0 most belongs to root, this might have security issue.

and this breaks these test cases:
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam.phpt]
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam_basic.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam_basic.phpt]

here is reproducible code from: Andreas Fink :
#include 
#include 
#include 
#include 
#include 

#define MAYBE_NULL_STRING(a)(a ? a : "(NULL)")

extern int errno;

int main(int argc, char *argv[])
{
errno = 0;
struct passwd *pwdstruct = getpwnam("");
printf("errno = %d\n",errno);
if(pwdstruct == NULL)
{
printf("pwdstruct == NULL\n");
exit(0);
}

printf("pw_name: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_name));
printf("pw_passwd: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_passwd));
printf("pw_uid: %d\n",pwdstruct->pw_uid);
printf("pw_gid: %d\n",pwdstruct->pw_gid);
}


produces

$ ./a.out 
errno = 0
pw_name: 
pw_passwd: 
pw_uid: 0
pw_gid: 0


Test script:
---

  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["uid"]=>
  int(0)
  ["gid"]=>
  int(0)
  ["gecos"]=>
  string(0) ""
  ["dir"]=>
  string(0) ""
  ["shell"]=>
  string(0) ""
}
array(4) {
  ["name"]=>
  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["members"]=>
  array(0) {
  }
  ["gid"]=>
  int(0)
}






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


Bug #62881 [Opn->Wfx]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread laruence
Edit report at https://bugs.php.net/bug.php?id=62881&edit=1

 ID: 62881
 Updated by: larue...@php.net
 Reported by:reeze dot xia at gmail dot com
 Summary:posix_getpwnam("") && posix_getgrnam("") didn't
 return false on Mac OSX 10.8
-Status: Open
+Status: Wont fix
 Type:   Bug
 Package:POSIX related
 Operating System:   Mac OSX 10.8
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

same comment copied from the pr:

we don't fix bug doesn't belong to php
Linux man page of posix_getpwnam doesn't specific the situation about empty 
string
Posix functions are buggy in mac os. so, won't fix for this, leave it to apple .
btw:

after a quick google, seems you have file a bug to apple, then file another bug 
to ruby..

and the ruby guy told you the same thing I told.

why you still think it should be fixed in php self?


Previous Comments:

[2012-08-21 17:06:22] reeze dot xia at gmail dot com

Hi,
  I'v sent a pull request for this bug:

https://github.com/php/php-src/pull/176


thanks


[2012-08-21 16:54:16] reeze dot xia at gmail dot com

Description:

In Mac OS X 10.8 mountain lion, getpwnam() && getgrnam() didn't return NULL
when empty string supplied. this is a bug of 10.8.0

since uid 0 an gid 0 most belongs to root, this might have security issue.

and this breaks these test cases:
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam.phpt]
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam_basic.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam_basic.phpt]

here is reproducible code from: Andreas Fink :
#include 
#include 
#include 
#include 
#include 

#define MAYBE_NULL_STRING(a)(a ? a : "(NULL)")

extern int errno;

int main(int argc, char *argv[])
{
errno = 0;
struct passwd *pwdstruct = getpwnam("");
printf("errno = %d\n",errno);
if(pwdstruct == NULL)
{
printf("pwdstruct == NULL\n");
exit(0);
}

printf("pw_name: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_name));
printf("pw_passwd: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_passwd));
printf("pw_uid: %d\n",pwdstruct->pw_uid);
printf("pw_gid: %d\n",pwdstruct->pw_gid);
}


produces

$ ./a.out 
errno = 0
pw_name: 
pw_passwd: 
pw_uid: 0
pw_gid: 0


Test script:
---

  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["uid"]=>
  int(0)
  ["gid"]=>
  int(0)
  ["gecos"]=>
  string(0) ""
  ["dir"]=>
  string(0) ""
  ["shell"]=>
  string(0) ""
}
array(4) {
  ["name"]=>
  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["members"]=>
  array(0) {
  }
  ["gid"]=>
  int(0)
}






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


[PHP-BUG] Bug #62885 [NEW]: mysqli_poll - Segmentation fault

2012-08-21 Thread mateusz dot goik at aliantsoft dot pl
From: mateusz dot goik at aliantsoft dot pl
Operating system: Backtrack 5r2
PHP version:  5.4Git-2012-08-21 (snap)
Package:  MySQLi related
Bug Type: Bug
Bug description:mysqli_poll - Segmentation fault

Description:

mysqli_poll - Segmentation fault

PHP 5.4.7-dev (cli) (built: Aug 22 2012 00:48:06) 

Program received signal SIGSEGV, Segmentation fault.
0x009051a1 in mysqlnd_stream_array_check_for_readiness
(conn_array=0x0) at
/home/test/php-trunk-201208212130/ext/mysqlnd/mysqlnd.c:1113
1113while (*p) {

Test script:
---


Actual result:
--
#0  0x009051a1 in mysqlnd_stream_array_check_for_readiness
(conn_array=0x0) at
/home/test/php-trunk-201208212130/ext/mysqlnd/mysqlnd.c:1113
#1  0x00905533 in _mysqlnd_poll (r_array=0x0, e_array=0x0,
dont_poll=0x7fff82480080, sec=0, usec=0, desc_num=0x7fff8248006c) at
/home/test/php-trunk-201208212130/ext/mysqlnd/mysqlnd.c:1223
#2  0x006e6012 in zif_mysqli_poll (ht=4,
return_value=0x7fb217b8b370, return_value_ptr=0x0, this_ptr=0x0,
return_value_used=1) at
/home/test/php-trunk-201208212130/ext/mysqli/mysqli_nonapi.c:791
#3  0x009fe45c in zend_do_fcall_common_helper_SPEC
(execute_data=0x7fb217b57060) at
/home/test/php-trunk-201208212130/Zend/zend_vm_execute.h:642
#4  0x00a05075 in ZEND_DO_FCALL_SPEC_CONST_HANDLER
(execute_data=0x7fb217b57060) at
/home/test/php-trunk-201208212130/Zend/zend_vm_execute.h:2219
#5  0x009fcefd in execute (op_array=0x7fb217b8ac50) at
/home/test/php-trunk-201208212130/Zend/zend_vm_execute.h:410
#6  0x009c38e3 in zend_execute_scripts (type=8, retval=0x0,
file_count=3) at /home/test/php-trunk-201208212130/Zend/zend.c:1286
#7  0x009413a4 in php_execute_script (primary_file=0x7fff82483940)
at /home/test/php-trunk-201208212130/main/main.c:2473
#8  0x00af847d in do_cli (argc=2, argv=0x7fff82483cf8) at
/home/test/php-trunk-201208212130/sapi/cli/php_cli.c:988
#9  0x00af92a3 in main (argc=2, argv=0x7fff82483cf8) at
/home/test/php-trunk-201208212130/sapi/cli/php_cli.c:1364


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



Bug #62884 [Opn]: parse_ini_file() results changed in 5.3.15

2012-08-21 Thread fidian at rumkin dot com
Edit report at https://bugs.php.net/bug.php?id=62884&edit=1

 ID: 62884
 User updated by:fidian at rumkin dot com
 Reported by:fidian at rumkin dot com
 Summary:parse_ini_file() results changed in 5.3.15
 Status: Open
 Type:   Bug
 Package:Unknown/Other Function
 Operating System:   Ubuntu Linus 12.04
 PHP Version:5.3Git-2012-08-21 (Git)
 Block user comment: N
 Private report: N

 New Comment:

For clarification, what Microsoft says is

If the string associated with lpKeyName is enclosed in single or double 
quotation marks, the marks are discarded when the GetPrivateProfileString 
function retrieves the string.

This leads me to believe that it merely checks if the first and last character 
match and if they are a " or ' and then would remove both the first and last 
character.


Previous Comments:

[2012-08-21 23:48:41] fidian at rumkin dot com

Description:

Given an INI file that looks like this

ini = "a"b"

and when you use parse_ini_file with INI_SCANNER_RAW, PHP used to return this 
as 
array('ini' => 'a"b') and now returns it as array('ini' => 'ab"').  This does 
not appear to match with Microsoft's GetPrivateProfileString 
(http://msdn.microsoft.com/en-us/library/ms724353(VS.85).aspx) where they say 
that values which are quoted with either single or double quotes are simply 
unquoted.  My expected behavior would be to mirror the Microsoft parser, 
especially when in raw mode.

Note:  I am not talking about changing INI_SCANNER_NORMAL, just the raw mode so 
I can get the unparsed values.

According to git-bisect, commit 4e6f27f4db6121e67f17906b27cc829120738b71 is the 
culprit, but I suspect that the fix for bug 51094 is really to blame.

Test script:
---
 'a"b',
)


Actual result:
--
array (
  'ini' => 'ab"',
)







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


[PHP-BUG] Bug #62884 [NEW]: parse_ini_file() results changed in 5.3.15

2012-08-21 Thread fidian at rumkin dot com
From: fidian at rumkin dot com
Operating system: Ubuntu Linus 12.04
PHP version:  5.3Git-2012-08-21 (Git)
Package:  Unknown/Other Function
Bug Type: Bug
Bug description:parse_ini_file() results changed in 5.3.15

Description:

Given an INI file that looks like this

ini = "a"b"

and when you use parse_ini_file with INI_SCANNER_RAW, PHP used to return
this as 
array('ini' => 'a"b') and now returns it as array('ini' => 'ab"').  This
does 
not appear to match with Microsoft's GetPrivateProfileString 
(http://msdn.microsoft.com/en-us/library/ms724353(VS.85).aspx) where they
say 
that values which are quoted with either single or double quotes are simply

unquoted.  My expected behavior would be to mirror the Microsoft parser, 
especially when in raw mode.

Note:  I am not talking about changing INI_SCANNER_NORMAL, just the raw
mode so 
I can get the unparsed values.

According to git-bisect, commit 4e6f27f4db6121e67f17906b27cc829120738b71 is
the 
culprit, but I suspect that the fix for bug 51094 is really to blame.

Test script:
---
 'a"b',
)


Actual result:
--
array (
  'ini' => 'ab"',
)


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



Req #62840 [Csd]: Add sort flag to ArrayObject::ksort

2012-08-21 Thread bert at becoded dot be
Edit report at https://bugs.php.net/bug.php?id=62840&edit=1

 ID: 62840
 User updated by:bert at becoded dot be
 Reported by:bert at becoded dot be
 Summary:Add sort flag to ArrayObject::ksort
 Status: Closed
 Type:   Feature/Change Request
 Package:SPL related
 PHP Version:5.4.5
 Assigned To:laruence
 Block user comment: N
 Private report: N

 New Comment:

Thx for the quick implementation!


Previous Comments:

[2012-08-21 06:24:12] larue...@php.net

yes, I noticed that, just I thought it was acceptable, there is the same issue 
in 
uasort.


[2012-08-21 05:59:06] reeze dot xia at gmail dot com

cool, I implemented it last night, but missing a better test case.
I think the error message isn't correct, so I didn't sent it.

you could see that, the warning message is not really exactly correct.
It just a proxy to call asort($obj, $flag) if the $flag is not valid.
It complained about the 2 parameter is not valid but not the first parameter.

$obj->sort('adfsd');  // 1
sort($ar, 'adfds');   // 2


[2012-08-21 05:30:45] larue...@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/.

 For Windows:

http://windows.php.net/snapshots/
 
Thank you for the report, and for helping us make PHP better.




[2012-08-21 05:30:07] larue...@php.net

hmm, after a quick look, this will be very easy to implemented. then I did it. 
:)


[2012-08-21 00:59:20] reeze dot xia at gmail dot com

Sounds reasonable to me I am working on a patch for this request.
Will send a pull request later.

Thanks




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

https://bugs.php.net/bug.php?id=62840


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


Bug #62880 [Opn]: Problems building a shared mysqlnd extension

2012-08-21 Thread lester at lsces dot co dot uk
Edit report at https://bugs.php.net/bug.php?id=62880&edit=1

 ID: 62880
 User updated by:lester at lsces dot co dot uk
 Reported by:lester at lsces dot co dot uk
 Summary:Problems building a shared mysqlnd extension
 Status: Open
 Type:   Bug
 Package:MySQLi related
 Operating System:   Linux
 PHP Version:5.4.6
 Block user comment: N
 Private report: N

 New Comment:

BUT the libphp5.so apache module is built at the same time as the mysqlnd.so 
module so why would they be different? Which had been an earlier suggestion to 
solve the problem.
Interestingly ... it worked ... so perhaps the question now is why is it 
needed? Why are the two files incompatible without "--enable-maintainer-zts"


Previous Comments:

[2012-08-21 17:08:49] ni...@php.net

The error suggests that you are trying to build mysqlnd without zts and try to 
load it in a php build with zts. Try adding --enable-maintainer-zts to your 
./configure line.


[2012-08-21 16:44:25] lester at lsces dot co dot uk

Description:

This may be by design, but it is also being claimed that it does in fact work, 
so the main object of this bug report is to get a documented confirmation of 
the situation.
Fixed bug http://bugs.php.net/55609 (mysqlnd cannot be built shared). 
(Johannes)  identifies the problem as having been fixed, but Rasmus claims that 
it is not intended that mysqlnd should be built stand alone?
In any case when building as an apache2 module, a shared module is created, but 
will not load with apache.  

Test script:
---
./configure --with-apxs2=/opt/apache2/bin/apxs --prefix=/opt/php5 
--with-config-file-path=/opt/apache2/conf 
--with-config-file-scan-dir=/opt/apache2/conf/php5.d --enable-mysqlnd=shared 
--with-mysqli=shared 

I'm sure that should be a "--with-mysqli=mysqlnd,shared" but that stops 
building of ./configure with a "can't find mysql" (Bug 50393)

Expected result:

mysqlnd.so and mysqli.so in the modules directory., which can be moved into the 
running PHP installation.

Actual result:
--
When loading mysqlnd.so via apache, it fails with an PHP Warning:  PHP Startup: 
Invalid library (maybe not a PHP library) 'mysqlnd.so' in Unknown on line 0 on 
the latest build, but I've also had
"Unable to load dynamic library '/opt/php5/ext/mysqlnd.so' - 
/opt/php5/ext/mysqlnd.so: undefined symbol: executor_globals in Unknown on line 
0"  So I am going to recheck everything on the next machine that needs updating






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


Req #26411 [Com]: while {} else {}

2012-08-21 Thread bensor987 at neuf dot fr
Edit report at https://bugs.php.net/bug.php?id=26411&edit=1

 ID: 26411
 Comment by: bensor987 at neuf dot fr
 Reported by:php at bellytime dot com
 Summary:while {} else {}
 Status: Open
 Type:   Feature/Change Request
 Package:Scripting Engine problem
 Operating System:   *
 PHP Version:*
 Block user comment: N
 Private report: N

 New Comment:

Why don't you go a little bit further ?

while ( $row = mysql_fetch_assoc( $result ) ){

} else for ( $i = 0; $i < $cpt; $i++ ) {

} else if ( $dude ) {

} else {

}


Previous Comments:

[2012-04-26 02:13:36] ma-martin at hotmail dot de

Hey, i was also looking for some while {} else {} feature...
but i think it could be difficult to implement such a function in php.
Because the else{} event would start after the while{}-loop ends -> everytime 
after the last result!
think about it!


[2012-01-25 12:16:57] hawkyhawk14 at gmail dot com

This is a great idea. I am currently needing something like this, but however 
got 
around it using flags and making the flag true in the while. It would be alot 
more 
convenient if there was an else!

Please add this feature!!!


[2011-12-06 16:31:22] absimu at hotmail dot com

I agree. I think a while () else () will make things easier. I was researching 
and 
found out that it doesnt exist yet. 


while($row = mysqli_fetch_assoc($result)) { }

with al else I would fix it.. I am new in PHP,. I will try to find something to 
fix it. but if the while else is release in a new version that would be nice.


[2011-02-18 01:14:34] ijrbiz at gmail dot com

Highly agreed, this request would be very practical for improved coding 
structure and 
follows logical language syntax nicely.

function remove_items (&$arr, $needle) {
while ($key = array_search($needle, $arr)) {
unset( $arr[$key] );
} else return false; // No items present
return true; // Item(s) removed
}


[2010-12-19 13:08:30] trefighter2334 at aol dot com

I'd love to see something like Python's while/else logic implemented in PHP.

This logical construct would allow developers to define blocks of code in else 
{} that'd run upon a natural exit from the while(){} loop caused by said loop's 
condition becoming FALSE; however, the else {} would be skipped over if the 
loop 
exits unnaturally -- a la through a break statement or because of an exception.

It is to die for on a semi-daily basis for me (in python)... but I'm not sure 
this is what the developers above (and their examples) have in mind or not.

Either implementation would prove useful to me.




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

https://bugs.php.net/bug.php?id=26411


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


Bug #62880 [Opn]: Problems building a shared mysqlnd extension

2012-08-21 Thread nikic
Edit report at https://bugs.php.net/bug.php?id=62880&edit=1

 ID: 62880
 Updated by: ni...@php.net
 Reported by:lester at lsces dot co dot uk
 Summary:Problems building a shared mysqlnd extension
 Status: Open
 Type:   Bug
 Package:MySQLi related
 Operating System:   Linux
 PHP Version:5.4.6
 Block user comment: N
 Private report: N

 New Comment:

The error suggests that you are trying to build mysqlnd without zts and try to 
load it in a php build with zts. Try adding --enable-maintainer-zts to your 
./configure line.


Previous Comments:

[2012-08-21 16:44:25] lester at lsces dot co dot uk

Description:

This may be by design, but it is also being claimed that it does in fact work, 
so the main object of this bug report is to get a documented confirmation of 
the situation.
Fixed bug http://bugs.php.net/55609 (mysqlnd cannot be built shared). 
(Johannes)  identifies the problem as having been fixed, but Rasmus claims that 
it is not intended that mysqlnd should be built stand alone?
In any case when building as an apache2 module, a shared module is created, but 
will not load with apache.  

Test script:
---
./configure --with-apxs2=/opt/apache2/bin/apxs --prefix=/opt/php5 
--with-config-file-path=/opt/apache2/conf 
--with-config-file-scan-dir=/opt/apache2/conf/php5.d --enable-mysqlnd=shared 
--with-mysqli=shared 

I'm sure that should be a "--with-mysqli=mysqlnd,shared" but that stops 
building of ./configure with a "can't find mysql" (Bug 50393)

Expected result:

mysqlnd.so and mysqli.so in the modules directory., which can be moved into the 
running PHP installation.

Actual result:
--
When loading mysqlnd.so via apache, it fails with an PHP Warning:  PHP Startup: 
Invalid library (maybe not a PHP library) 'mysqlnd.so' in Unknown on line 0 on 
the latest build, but I've also had
"Unable to load dynamic library '/opt/php5/ext/mysqlnd.so' - 
/opt/php5/ext/mysqlnd.so: undefined symbol: executor_globals in Unknown on line 
0"  So I am going to recheck everything on the next machine that needs updating






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


Bug #62881 [Com]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread reeze dot xia at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=62881&edit=1

 ID: 62881
 Comment by: reeze dot xia at gmail dot com
 Reported by:reeze dot xia at gmail dot com
 Summary:posix_getpwnam("") && posix_getgrnam("") didn't
 return false on Mac OSX 10.8
 Status: Open
 Type:   Bug
 Package:POSIX related
 Operating System:   Mac OSX 10.8
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

Hi,
  I'v sent a pull request for this bug:

https://github.com/php/php-src/pull/176


thanks


Previous Comments:

[2012-08-21 16:54:16] reeze dot xia at gmail dot com

Description:

In Mac OS X 10.8 mountain lion, getpwnam() && getgrnam() didn't return NULL
when empty string supplied. this is a bug of 10.8.0

since uid 0 an gid 0 most belongs to root, this might have security issue.

and this breaks these test cases:
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam.phpt]
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam_basic.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam_basic.phpt]

here is reproducible code from: Andreas Fink :
#include 
#include 
#include 
#include 
#include 

#define MAYBE_NULL_STRING(a)(a ? a : "(NULL)")

extern int errno;

int main(int argc, char *argv[])
{
errno = 0;
struct passwd *pwdstruct = getpwnam("");
printf("errno = %d\n",errno);
if(pwdstruct == NULL)
{
printf("pwdstruct == NULL\n");
exit(0);
}

printf("pw_name: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_name));
printf("pw_passwd: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_passwd));
printf("pw_uid: %d\n",pwdstruct->pw_uid);
printf("pw_gid: %d\n",pwdstruct->pw_gid);
}


produces

$ ./a.out 
errno = 0
pw_name: 
pw_passwd: 
pw_uid: 0
pw_gid: 0


Test script:
---

  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["uid"]=>
  int(0)
  ["gid"]=>
  int(0)
  ["gecos"]=>
  string(0) ""
  ["dir"]=>
  string(0) ""
  ["shell"]=>
  string(0) ""
}
array(4) {
  ["name"]=>
  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["members"]=>
  array(0) {
  }
  ["gid"]=>
  int(0)
}






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


[PHP-BUG] Bug #62881 [NEW]: posix_getpwnam("") && posix_getgrnam("") didn't return false on Mac OSX 10.8

2012-08-21 Thread reeze dot xia at gmail dot com
From: reeze dot xia at gmail dot com
Operating system: Mac OSX 10.8
PHP version:  Irrelevant
Package:  POSIX related
Bug Type: Bug
Bug description:posix_getpwnam("") && posix_getgrnam("") didn't return false on 
Mac OSX 10.8

Description:

In Mac OS X 10.8 mountain lion, getpwnam() && getgrnam() didn't return
NULL
when empty string supplied. this is a bug of 10.8.0

since uid 0 an gid 0 most belongs to root, this might have security issue.

and this breaks these test cases:
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam.phpt]
posix_getgrnam(): Basic tests [ext/posix/tests/posix_getgrnam_basic.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam.phpt]
posix_getpwnam(): Basic tests [ext/posix/tests/posix_getpwnam_basic.phpt]

here is reproducible code from: Andreas Fink :
#include 
#include 
#include 
#include 
#include 

#define MAYBE_NULL_STRING(a)(a ? a : "(NULL)")

extern int errno;

int main(int argc, char *argv[])
{
errno = 0;
struct passwd *pwdstruct = getpwnam("");
printf("errno = %d\n",errno);
if(pwdstruct == NULL)
{
printf("pwdstruct == NULL\n");
exit(0);
}

printf("pw_name: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_name));
printf("pw_passwd: %s\n",MAYBE_NULL_STRING(pwdstruct->pw_passwd));
printf("pw_uid: %d\n",pwdstruct->pw_uid);
printf("pw_gid: %d\n",pwdstruct->pw_gid);
}


produces

$ ./a.out 
errno = 0
pw_name: 
pw_passwd: 
pw_uid: 0
pw_gid: 0


Test script:
---

  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["uid"]=>
  int(0)
  ["gid"]=>
  int(0)
  ["gecos"]=>
  string(0) ""
  ["dir"]=>
  string(0) ""
  ["shell"]=>
  string(0) ""
}
array(4) {
  ["name"]=>
  string(0) ""
  ["passwd"]=>
  string(0) ""
  ["members"]=>
  array(0) {
  }
  ["gid"]=>
  int(0)
}

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



[PHP-BUG] Bug #62880 [NEW]: Problems building a shared mysqlnd extension

2012-08-21 Thread lester at lsces dot co dot uk
From: lester at lsces dot co dot uk
Operating system: Linux
PHP version:  5.4.6
Package:  MySQLi related
Bug Type: Bug
Bug description:Problems building a shared mysqlnd extension

Description:

This may be by design, but it is also being claimed that it does in fact
work, so the main object of this bug report is to get a documented
confirmation of the situation.
Fixed bug http://bugs.php.net/55609 (mysqlnd cannot be built shared).
(Johannes)  identifies the problem as having been fixed, but Rasmus claims
that it is not intended that mysqlnd should be built stand alone?
In any case when building as an apache2 module, a shared module is created,
but will not load with apache.  

Test script:
---
./configure --with-apxs2=/opt/apache2/bin/apxs --prefix=/opt/php5
--with-config-file-path=/opt/apache2/conf
--with-config-file-scan-dir=/opt/apache2/conf/php5.d
--enable-mysqlnd=shared --with-mysqli=shared 

I'm sure that should be a "--with-mysqli=mysqlnd,shared" but that stops
building of ./configure with a "can't find mysql" (Bug 50393)

Expected result:

mysqlnd.so and mysqli.so in the modules directory., which can be moved into
the running PHP installation.

Actual result:
--
When loading mysqlnd.so via apache, it fails with an PHP Warning:  PHP
Startup: Invalid library (maybe not a PHP library) 'mysqlnd.so' in Unknown
on line 0 on the latest build, but I've also had
"Unable to load dynamic library '/opt/php5/ext/mysqlnd.so' -
/opt/php5/ext/mysqlnd.so: undefined symbol: executor_globals in Unknown on
line 0"  So I am going to recheck everything on the next machine that needs
updating

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



Bug #62879 [Opn->Nab]: Incorrect Array Size when fetching Array

2012-08-21 Thread rasmus
Edit report at https://bugs.php.net/bug.php?id=62879&edit=1

 ID: 62879
 Updated by: ras...@php.net
 Reported by:joseph dot morain at live dot ca
 Summary:Incorrect Array Size when fetching Array
-Status: Open
+Status: Not a bug
 Type:   Bug
 Package:MySQLi related
 Operating System:   Linux
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

mysqli_fetch_array() by default gives you both numeric and associative indices 
for each row. Pass in MYSQLI_ASSOC or MYSQLI_NUM to get just one of them.


Previous Comments:

[2012-08-21 16:03:14] joseph dot morain at live dot ca

Description:

Hi I'm using PHP 5.4.4 (Didn't see option for this).

I have a trivial table called staff with 3 rows and 1 record 

staff_id : 555
email : baconator_k...@baconation.com
password : 1_b@c0n@73_8Ab1Es

whenever I try to fetch array however it multiplies the data by 2!
I've posted a short little program which illustrates my problem. 

There is a similar problem here : https://bugs.php.net/bug.php?id=60333
but it was dealing with a slightly different function so I didn't append that 
bug report. 




Test script:
---
include('_commons.php');
$con = dbopen();
$results = mysqli_query($con,'SELECT  * FROM Staff;');
while($row = mysqli_fetch_array($results)){
foreach($row as $t){
echo $t.'';
}
}
dbclose($con);

Expected result:

555
baconator_k...@baconation.com
1_b@c0n@73_8Ab1Es

Actual result:
--
555
555
baconator_k...@baconation.com
baconator_k...@baconation.com
1_b@c0n@73_8Ab1Es
1_b@c0n@73_8Ab1Es






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


[PHP-BUG] Bug #62879 [NEW]: Incorrect Array Size when fetching Array

2012-08-21 Thread joseph dot morain at live dot ca
From: joseph dot morain at live dot ca
Operating system: Linux
PHP version:  Irrelevant
Package:  MySQLi related
Bug Type: Bug
Bug description:Incorrect Array Size when fetching Array

Description:

Hi I'm using PHP 5.4.4 (Didn't see option for this).

I have a trivial table called staff with 3 rows and 1 record 

staff_id : 555
email : baconator_k...@baconation.com
password : 1_b@c0n@73_8Ab1Es

whenever I try to fetch array however it multiplies the data by 2!
I've posted a short little program which illustrates my problem. 

There is a similar problem here : https://bugs.php.net/bug.php?id=60333
but it was dealing with a slightly different function so I didn't append
that 
bug report. 




Test script:
---
include('_commons.php');
$con = dbopen();
$results = mysqli_query($con,'SELECT  * FROM Staff;');
while($row = mysqli_fetch_array($results)){
foreach($row as $t){
echo $t.'';
}
}
dbclose($con);

Expected result:

555
baconator_k...@baconation.com
1_b@c0n@73_8Ab1Es

Actual result:
--
555
555
baconator_k...@baconation.com
baconator_k...@baconation.com
1_b@c0n@73_8Ab1Es
1_b@c0n@73_8Ab1Es

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



Bug #62874 [Com]: getDefaultValue() fails

2012-08-21 Thread crash__ at hotmail dot fr
Edit report at https://bugs.php.net/bug.php?id=62874&edit=1

 ID: 62874
 Comment by: crash__ at hotmail dot fr
 Reported by:karsten at typo3 dot org
 Summary:getDefaultValue() fails
 Status: Closed
 Type:   Bug
 Package:Reflection related
 Operating System:   OS X
 PHP Version:5.3.16
 Assigned To:laruence
 Block user comment: N
 Private report: N

 New Comment:

I have a similar bug with the doctrine's generation proxies on GNU/Linux.

So can we expect a 5.3.17 version soon?


Previous Comments:

[2012-08-21 10:08:52] larue...@php.net

yeah, that bug was fixed after 5.4.0

since problem gone, I will close this


[2012-08-21 07:45:41] karsten at typo3 dot org

Indeed, my test script runs with the expected output on php5.3-latest.

And the output of 5.3 and 5.4 differ when it comes to isDefaultValueAvailable() 
- 
see https://gist.github.com/724fbc1e29fb7b0bad59 - failed because on 5.4.0 the 
bug 
#62715 did still exist.


[2012-08-21 05:42:51] larue...@php.net

seems it already be fixed. please try with the 5.3-master snapshot


[2012-08-21 05:41:58] larue...@php.net

Please try using this snapshot:

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

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




[2012-08-20 14:27:41] karsten at typo3 dot org

You mean https://bugs.php.net/62715 - it brought me on track. I have a report 
for 
my test script ran on 5.4 that results in 
https://gist.github.com/467127b13f987b1633d9, so it seems 
isDefaultValueAvailable() returns false there…




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

https://bugs.php.net/bug.php?id=62874


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


Bug #61272 [Com]: ob_start callback get passed empty string

2012-08-21 Thread a dot vi at laposte dot net
Edit report at https://bugs.php.net/bug.php?id=61272&edit=1

 ID: 61272
 Comment by: a dot vi at laposte dot net
 Reported by:peacech at gmail dot com
 Summary:ob_start callback get passed empty string
 Status: Re-Opened
 Type:   Bug
 Package:Output Control
 Operating System:   Arch 32 bit
 PHP Version:5.4.0
 Block user comment: N
 Private report: N

 New Comment:

Same problem here with PHP5.4.6. I've had to patch my application and use:
ob_end_flush();
ob_clean();
instead of:
ob_end_clean();

I really agree with Casper: if this is not a change of behavior, this is a bug. 
My application was working really fine with PHP5.3.8 but was broken with 
PHP5.4.6. So something has changed 

Kind regards


Previous Comments:

[2012-07-10 08:59:04] dragon829 at gmail dot com

We have the same problem in 5.4.4,and it hasn't reproduced in 5.3.14 .


[2012-06-08 08:03:50] casper at langemeijer dot eu

Mike, I've dug a bit deeper into this problem, and must conclude that this 
really is a bug, or at least a change of behaviour.

I think test tests/output/ob_017.phpt is faulty too. I corrected bot output.c 
and the test in the patch I supplied.

In PHP 5.3 the callback function is called with the contents of the output 
buffer when ob_clean or ob_end_clean is called. The output will be fed to the 
callback function, but is erased right after that call.

After your output buffering rewrite the output buffer is cleaned before the 
callback is called.

I see no valid reason for a functional change. You're supplying the callback 
with a flag so that if needed the callback function could do this itself if 
needed.


[2012-05-18 10:04:18] patrick at procurios dot nl

We are having the same problem and it keeps us from migrating to 5.4. Could you 
please fix it?


[2012-03-05 14:43:25] peacech at gmail dot com

Unless ob_start callback specification has changed that for 
ob_clean/ob_end_clean, the output is discarded before calling the callback, 
then this is a bug. And I have scan the PHP 5.4 changelog and couldn't find 
anything mentioning this change.

So let me help by showing where the problem is

In line 1226 of output.c in the distributed PHP 5.4.0 source,

if (flags & PHP_OUTPUT_POP_DISCARD) {
context.op |= PHP_OUTPUT_HANDLER_CLEAN;
orphan->buffer.used = 0;
}
php_output_handler_op(orphan, &context);

orphan->buffer.used should not be set to 0 before calling the callback, 
otherwise the callback will be called with empty buffer.

And likewise in line 300 in php_output_clean

So, no, it isn't about appending $output to $buffer.


[2012-03-05 11:23:43] m...@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.

You should append $output to $buffer.




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

https://bugs.php.net/bug.php?id=61272


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


Bug #62874 [Fbk->Csd]: getDefaultValue() fails

2012-08-21 Thread laruence
Edit report at https://bugs.php.net/bug.php?id=62874&edit=1

 ID: 62874
 Updated by: larue...@php.net
 Reported by:karsten at typo3 dot org
 Summary:getDefaultValue() fails
-Status: Feedback
+Status: Closed
 Type:   Bug
 Package:Reflection related
 Operating System:   OS X
 PHP Version:5.3.16
 Assigned To:laruence
 Block user comment: N
 Private report: N

 New Comment:

yeah, that bug was fixed after 5.4.0

since problem gone, I will close this


Previous Comments:

[2012-08-21 07:45:41] karsten at typo3 dot org

Indeed, my test script runs with the expected output on php5.3-latest.

And the output of 5.3 and 5.4 differ when it comes to isDefaultValueAvailable() 
- 
see https://gist.github.com/724fbc1e29fb7b0bad59 - failed because on 5.4.0 the 
bug 
#62715 did still exist.


[2012-08-21 05:42:51] larue...@php.net

seems it already be fixed. please try with the 5.3-master snapshot


[2012-08-21 05:41:58] larue...@php.net

Please try using this snapshot:

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

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




[2012-08-20 14:27:41] karsten at typo3 dot org

You mean https://bugs.php.net/62715 - it brought me on track. I have a report 
for 
my test script ran on 5.4 that results in 
https://gist.github.com/467127b13f987b1633d9, so it seems 
isDefaultValueAvailable() returns false there…


[2012-08-20 14:04:10] larue...@php.net

hmm,  I fixed a similar bug before, I still think it's a wrong usage..

however I will fix this later.




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

https://bugs.php.net/bug.php?id=62874


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


Bug #61859 [Fbk->Opn]: pdo fails on make

2012-08-21 Thread aharvey
Edit report at https://bugs.php.net/bug.php?id=61859&edit=1

 ID: 61859
 Updated by: ahar...@php.net
 Reported by:gencer at cmail dot cm
 Summary:pdo fails on make
-Status: Feedback
+Status: Open
 Type:   Bug
 Package:Compile Failure
 Operating System:   CentOS 5.8 x86_64
 PHP Version:5.4.1
 Block user comment: N
 Private report: N



Previous Comments:

[2012-08-21 08:28:40] paszczak000 at gmail dot com

Package glibc-2.12-1.80.el6_3.4.x86_64 already installed and latest version
Package gcc-4.4.6-4.el6.x86_64 already installed and latest version
Package glibc-devel-2.12-1.80.el6_3.4.x86_64 already installed and latest 
version
Package autoconf-2.63-5.1.el6.noarch already installed and latest version

Manually changing dirs helps, but this is workaround.


[2012-08-21 08:24:50] gencer at cmail dot cm

@paszczak000

It is all because of GLIBC and GCC. Make sure that you have autoconf installed. 
Re unpack tar.gz and recompile again. If this bug still exist manually change 
pdo/ with ext/pdo in .h files.

I hope this helps.

(yum install glibc gcc glibc-devel autoconf)


[2012-08-21 07:45:09] paszczak000 at gmail dot com

The same result with: 5.4.6 on CentOS release 6.3 (Final).


[2012-06-16 09:01:29] paszczak000 at gmail dot com

The same error I have on CentOS release 6.2 (Final) - 
2.6.32-220.13.1.el6.centos.plus.x86_64.

./configure --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin 
--sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share 
--includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec 
--localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man 
--infodir=/usr/share/info --cache-file=../config.cache --with-libdir=lib64 
--with-config-file-path=/etc --with-config-file-scan-dir=/etc/php.d 
--disable-debug --with-pic --disable-rpath --without-pear --with-bz2 
--with-curl --with-freetype-dir=/usr --with-gd --enable-gd-jis-conv 
--enable-gd-native-ttf --with-gdbm --with-gmp --enable-mbstring --with-iconv 
--with-jpeg-dir=/usr --with-pspell -with-zlib --with-zlib-dir=/usr/include 
--with-layout=GNU --enable-exif --enable-ftp --enable-sockets --enable-sysvsem 
--enable-sysvshm --enable-sysvmsg --enable-wddx --with-unixODBC=shared,/usr 
--enable-shmop --enable-calendar --without-sqlite3 --without-pdo-sqlite 
--with-libxml-dir=/usr --with-mhash --with-mcrypt --with-apxs2 --disable-dba 
--without-unixODBC --enable-json --with-mysql --with-mysqli --enable-soap 
--with-imap-ssl --with-imap --with-openssl --with-kerberos --enable-bcmath 
--with-pdo-mysql --with-pear=/usr/lib/php --with-gettext

But version PHP 5.4.1 with the same options in compiling very well.


[2012-05-01 06:44:14] gencer at cmail dot cm

Here is the full configure pattern:

'./configure' '--build=x86_64-redhat-linux-gnu' 
'--host=x86_64-redhat-linux-gnu' '--target=x86_64-redhat-linux-gnu' 
'--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' 
'--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' 
'--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' 
'--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' 
'--infodir=/usr/share/info' '--cache-file=../config.cache' 
'--with-libdir=lib64' '--with-config-file-path=/etc' 
'--with-config-file-scan-dir=/etc/php.d' '--disable-debug' '--with-pic' 
'--disable-rpath' '--without-pear' '--with-bz2' '--with-exec-dir=/usr/bin' 
'--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-xpm-dir=/usr' 
'--enable-gd-native-ttf' '--with-t1lib=/usr' '--without-gdbm' '--with-gettext' 
'--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' 
'--with-pcre-regex' '--with-zlib' '--with-layout=GNU' '--enable-exif' 
'--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--with-kerberos' 
'--enable-ucd-snmp-hack' '--enable-shmop' '--enable-calendar' 
'--with-libxml-dir=/usr' '--enable-libxml' '--with-xmlrpc' '--enable-xml' 
'--with-system-tzdata' '--with-mhash' '--with-mysql' '--with-gd' '--enable-dom' 
'--disable-dba' '--without-unixODBC--disable-xmlreader' '--disable-xmlwriter' 
'--without-sqlite' '--with-sqlite3' '--enable-phar' '--enable-fileinfo' 
'--enable-json' '--without-pspell' '--disable-wddx' '--without-curl' 
'--disable-posix' '--disable-sysvmsg' '--disable-sysvshm' '--disable-sysvsem' 
'--enable-pdo' '--enable-mbstring' '--enable-fastcgi' '--with-mcrypt' 
'--enable-fpm' '--with-mysqli=/usr/bin/mysql_config' '--with-pdo-mysql' 
'--enable-pcntl' '--with-imap=../imap/imap-2007f' '--with-imap-ssl' 
'--with-pgsql=/usr/pgsql-9.

Bug #61859 [Com]: pdo fails on make

2012-08-21 Thread paszczak000 at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=61859&edit=1

 ID: 61859
 Comment by: paszczak000 at gmail dot com
 Reported by:gencer at cmail dot cm
 Summary:pdo fails on make
 Status: Feedback
 Type:   Bug
 Package:Compile Failure
 Operating System:   CentOS 5.8 x86_64
 PHP Version:5.4.1
 Block user comment: N
 Private report: N

 New Comment:

Package glibc-2.12-1.80.el6_3.4.x86_64 already installed and latest version
Package gcc-4.4.6-4.el6.x86_64 already installed and latest version
Package glibc-devel-2.12-1.80.el6_3.4.x86_64 already installed and latest 
version
Package autoconf-2.63-5.1.el6.noarch already installed and latest version

Manually changing dirs helps, but this is workaround.


Previous Comments:

[2012-08-21 08:24:50] gencer at cmail dot cm

@paszczak000

It is all because of GLIBC and GCC. Make sure that you have autoconf installed. 
Re unpack tar.gz and recompile again. If this bug still exist manually change 
pdo/ with ext/pdo in .h files.

I hope this helps.

(yum install glibc gcc glibc-devel autoconf)


[2012-08-21 07:45:09] paszczak000 at gmail dot com

The same result with: 5.4.6 on CentOS release 6.3 (Final).


[2012-06-16 09:01:29] paszczak000 at gmail dot com

The same error I have on CentOS release 6.2 (Final) - 
2.6.32-220.13.1.el6.centos.plus.x86_64.

./configure --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin 
--sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share 
--includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec 
--localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man 
--infodir=/usr/share/info --cache-file=../config.cache --with-libdir=lib64 
--with-config-file-path=/etc --with-config-file-scan-dir=/etc/php.d 
--disable-debug --with-pic --disable-rpath --without-pear --with-bz2 
--with-curl --with-freetype-dir=/usr --with-gd --enable-gd-jis-conv 
--enable-gd-native-ttf --with-gdbm --with-gmp --enable-mbstring --with-iconv 
--with-jpeg-dir=/usr --with-pspell -with-zlib --with-zlib-dir=/usr/include 
--with-layout=GNU --enable-exif --enable-ftp --enable-sockets --enable-sysvsem 
--enable-sysvshm --enable-sysvmsg --enable-wddx --with-unixODBC=shared,/usr 
--enable-shmop --enable-calendar --without-sqlite3 --without-pdo-sqlite 
--with-libxml-dir=/usr --with-mhash --with-mcrypt --with-apxs2 --disable-dba 
--without-unixODBC --enable-json --with-mysql --with-mysqli --enable-soap 
--with-imap-ssl --with-imap --with-openssl --with-kerberos --enable-bcmath 
--with-pdo-mysql --with-pear=/usr/lib/php --with-gettext

But version PHP 5.4.1 with the same options in compiling very well.


[2012-05-01 06:44:14] gencer at cmail dot cm

Here is the full configure pattern:

'./configure' '--build=x86_64-redhat-linux-gnu' 
'--host=x86_64-redhat-linux-gnu' '--target=x86_64-redhat-linux-gnu' 
'--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' 
'--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' 
'--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' 
'--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' 
'--infodir=/usr/share/info' '--cache-file=../config.cache' 
'--with-libdir=lib64' '--with-config-file-path=/etc' 
'--with-config-file-scan-dir=/etc/php.d' '--disable-debug' '--with-pic' 
'--disable-rpath' '--without-pear' '--with-bz2' '--with-exec-dir=/usr/bin' 
'--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-xpm-dir=/usr' 
'--enable-gd-native-ttf' '--with-t1lib=/usr' '--without-gdbm' '--with-gettext' 
'--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' 
'--with-pcre-regex' '--with-zlib' '--with-layout=GNU' '--enable-exif' 
'--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--with-kerberos' 
'--enable-ucd-snmp-hack' '--enable-shmop' '--enable-calendar' 
'--with-libxml-dir=/usr' '--enable-libxml' '--with-xmlrpc' '--enable-xml' 
'--with-system-tzdata' '--with-mhash' '--with-mysql' '--with-gd' '--enable-dom' 
'--disable-dba' '--without-unixODBC--disable-xmlreader' '--disable-xmlwriter' 
'--without-sqlite' '--with-sqlite3' '--enable-phar' '--enable-fileinfo' 
'--enable-json' '--without-pspell' '--disable-wddx' '--without-curl' 
'--disable-posix' '--disable-sysvmsg' '--disable-sysvshm' '--disable-sysvsem' 
'--enable-pdo' '--enable-mbstring' '--enable-fastcgi' '--with-mcrypt' 
'--enable-fpm' '--with-mysqli=/usr/bin/mysql_config' '--with-pdo-mysql' 
'--enable-pcntl' '--with-imap=../imap/imap-2007f' '--with-imap-ssl' 
'--with-pgsql=/usr/pgsql-9.1' '--with-pdo-pgsql=/usr/pgsql-9.1'

Please allow me to remind this. This is not only for postgresql also pdo_mysql 
and pd

Bug #61859 [Com]: pdo fails on make

2012-08-21 Thread gencer at cmail dot cm
Edit report at https://bugs.php.net/bug.php?id=61859&edit=1

 ID: 61859
 Comment by: gencer at cmail dot cm
 Reported by:gencer at cmail dot cm
 Summary:pdo fails on make
 Status: Feedback
 Type:   Bug
 Package:Compile Failure
 Operating System:   CentOS 5.8 x86_64
 PHP Version:5.4.1
 Block user comment: N
 Private report: N

 New Comment:

@paszczak000

It is all because of GLIBC and GCC. Make sure that you have autoconf installed. 
Re unpack tar.gz and recompile again. If this bug still exist manually change 
pdo/ with ext/pdo in .h files.

I hope this helps.

(yum install glibc gcc glibc-devel autoconf)


Previous Comments:

[2012-08-21 07:45:09] paszczak000 at gmail dot com

The same result with: 5.4.6 on CentOS release 6.3 (Final).


[2012-06-16 09:01:29] paszczak000 at gmail dot com

The same error I have on CentOS release 6.2 (Final) - 
2.6.32-220.13.1.el6.centos.plus.x86_64.

./configure --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin 
--sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share 
--includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec 
--localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man 
--infodir=/usr/share/info --cache-file=../config.cache --with-libdir=lib64 
--with-config-file-path=/etc --with-config-file-scan-dir=/etc/php.d 
--disable-debug --with-pic --disable-rpath --without-pear --with-bz2 
--with-curl --with-freetype-dir=/usr --with-gd --enable-gd-jis-conv 
--enable-gd-native-ttf --with-gdbm --with-gmp --enable-mbstring --with-iconv 
--with-jpeg-dir=/usr --with-pspell -with-zlib --with-zlib-dir=/usr/include 
--with-layout=GNU --enable-exif --enable-ftp --enable-sockets --enable-sysvsem 
--enable-sysvshm --enable-sysvmsg --enable-wddx --with-unixODBC=shared,/usr 
--enable-shmop --enable-calendar --without-sqlite3 --without-pdo-sqlite 
--with-libxml-dir=/usr --with-mhash --with-mcrypt --with-apxs2 --disable-dba 
--without-unixODBC --enable-json --with-mysql --with-mysqli --enable-soap 
--with-imap-ssl --with-imap --with-openssl --with-kerberos --enable-bcmath 
--with-pdo-mysql --with-pear=/usr/lib/php --with-gettext

But version PHP 5.4.1 with the same options in compiling very well.


[2012-05-01 06:44:14] gencer at cmail dot cm

Here is the full configure pattern:

'./configure' '--build=x86_64-redhat-linux-gnu' 
'--host=x86_64-redhat-linux-gnu' '--target=x86_64-redhat-linux-gnu' 
'--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' 
'--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' 
'--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' 
'--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' 
'--infodir=/usr/share/info' '--cache-file=../config.cache' 
'--with-libdir=lib64' '--with-config-file-path=/etc' 
'--with-config-file-scan-dir=/etc/php.d' '--disable-debug' '--with-pic' 
'--disable-rpath' '--without-pear' '--with-bz2' '--with-exec-dir=/usr/bin' 
'--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-xpm-dir=/usr' 
'--enable-gd-native-ttf' '--with-t1lib=/usr' '--without-gdbm' '--with-gettext' 
'--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' 
'--with-pcre-regex' '--with-zlib' '--with-layout=GNU' '--enable-exif' 
'--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--with-kerberos' 
'--enable-ucd-snmp-hack' '--enable-shmop' '--enable-calendar' 
'--with-libxml-dir=/usr' '--enable-libxml' '--with-xmlrpc' '--enable-xml' 
'--with-system-tzdata' '--with-mhash' '--with-mysql' '--with-gd' '--enable-dom' 
'--disable-dba' '--without-unixODBC--disable-xmlreader' '--disable-xmlwriter' 
'--without-sqlite' '--with-sqlite3' '--enable-phar' '--enable-fileinfo' 
'--enable-json' '--without-pspell' '--disable-wddx' '--without-curl' 
'--disable-posix' '--disable-sysvmsg' '--disable-sysvshm' '--disable-sysvsem' 
'--enable-pdo' '--enable-mbstring' '--enable-fastcgi' '--with-mcrypt' 
'--enable-fpm' '--with-mysqli=/usr/bin/mysql_config' '--with-pdo-mysql' 
'--enable-pcntl' '--with-imap=../imap/imap-2007f' '--with-imap-ssl' 
'--with-pgsql=/usr/pgsql-9.1' '--with-pdo-pgsql=/usr/pgsql-9.1'

Please allow me to remind this. This is not only for postgresql also pdo_mysql 
and pdo_sqlite too.

These errors happend to me after i updated/upgraded my linux system to the 
latest updates/versions. (like gcc, glibc etc.) All updates are stable and 
released by CentOS (but not by other 3rd parties).

Few weeks ago i havd no errors with this. But now i have.


[2012-04-30 21:08:17] s...@php.net

What were the original configure options (and other commands, if any) you used 
that produced t

Bug #62875 [Opn]: base64_encode broken with binary string

2012-08-21 Thread robertleglu at msn dot com
Edit report at https://bugs.php.net/bug.php?id=62875&edit=1

 ID: 62875
 User updated by:robertleglu at msn dot com
 Reported by:robertleglu at msn dot com
 Summary:base64_encode broken with binary string
 Status: Open
 Type:   Bug
 Package:URL related
 Operating System:   z/OS
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

I continue searching and i am pretty sure that the internal routines is written 
with an ascii table somewhere.

I was testing my routine called portable_base64_encode on z/OS and was confused 
because it seems to be wrong.
Here is the result :

str : A base64_encode : QQ== portable_base64_encode : wQ==
str : ABC base64_encode : QUJD portable_base64_encode : wcLD

But, although the built-in function may seem right and mine seems wrong,
the fact is that the binary code of 'A' 'B' and 'C' are not 65, 66 and 67, but 
193, 194 and 195 in EBCDIC.

So, even for a human-readable string, the built-in routine is wrong because 
base64 is intended to encode a binary flow...


Previous Comments:

[2012-08-20 15:25:56] ras...@php.net

reeze, it isn't really OS-specific but rather EBCDIC-specific. We have EBCDIC 
hacks in a few places, but I guess nobody bothered to make base64_encode EBCDIC-
safe.


[2012-08-20 15:23:24] reeze dot xia at gmail dot com

I can't reproduce it.

http://3v4l.org/GIL8C

It seems a OS specific bug. and I can't get a z/OS :(


[2012-08-20 14:29:22] robertleglu at msn dot com

Description:

problem occurs on z/OS 1.11 (OS of IBM mainframe) with latest version of php 
for 
that system.

binary strings are badly encoded with base64_encode.
rewriting my own (portable) version bypass the problem.


php version : (php_cli --version)
PHP 5.1.2 (cli) (built: Sep 28 2010 16:33:24)
Copyright (c) 1997-2006 The PHP Group
Zend Engine v2.1.0, Copyright (c) 1998-2006 Zend Technologies

Note that z/OS works in EBCDIC, so any code that assume ascii code, ascii order 
and ascii continuity is broken 






Test script:
---


Expected result:

R0ku


Actual result:
--
5fEG








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


Bug #62874 [Com]: getDefaultValue() fails

2012-08-21 Thread karsten at typo3 dot org
Edit report at https://bugs.php.net/bug.php?id=62874&edit=1

 ID: 62874
 Comment by: karsten at typo3 dot org
 Reported by:karsten at typo3 dot org
 Summary:getDefaultValue() fails
 Status: Feedback
 Type:   Bug
 Package:Reflection related
 Operating System:   OS X
 PHP Version:5.3.16
 Assigned To:laruence
 Block user comment: N
 Private report: N

 New Comment:

Indeed, my test script runs with the expected output on php5.3-latest.

And the output of 5.3 and 5.4 differ when it comes to isDefaultValueAvailable() 
- 
see https://gist.github.com/724fbc1e29fb7b0bad59 - failed because on 5.4.0 the 
bug 
#62715 did still exist.


Previous Comments:

[2012-08-21 05:42:51] larue...@php.net

seems it already be fixed. please try with the 5.3-master snapshot


[2012-08-21 05:41:58] larue...@php.net

Please try using this snapshot:

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

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




[2012-08-20 14:27:41] karsten at typo3 dot org

You mean https://bugs.php.net/62715 - it brought me on track. I have a report 
for 
my test script ran on 5.4 that results in 
https://gist.github.com/467127b13f987b1633d9, so it seems 
isDefaultValueAvailable() returns false there…


[2012-08-20 14:04:10] larue...@php.net

hmm,  I fixed a similar bug before, I still think it's a wrong usage..

however I will fix this later.


[2012-08-20 13:22:42] karsten at typo3 dot org

Description:

If isDefaultValueAvailable() returns TRUE I expect to be able to call 
getDefaultValue()

Test script:
---
getMethods() as $method) {
foreach ($method->getParameters() as $p) {
echo $p->getName() . "\n";
echo "   isDefaultValueAvailable: " . 
var_export($p->isDefaultValueAvailable(), true) . "\n";
if ($p->isDefaultValueAvailable()) {
echo "default value: " . 
var_export($p->getDefaultValue(), true) . "\n";
}
echo "isOptional: " . var_export($p->isOptional(), true) . "\n";
echo "allowsNull: " . var_export($p->allowsNull(), true) . "\n";
echo "\n";
}
}
?>

Expected result:

a
   isDefaultValueAvailable: true
default value: NULL
isOptional: false
allowsNull: true

b
   isDefaultValueAvailable: false
isOptional: false
allowsNull: true

c
   isDefaultValueAvailable: true
default value: NULL
isOptional: true
allowsNull: true

Actual result:
--
a
   isDefaultValueAvailable: true

Fatal error: Uncaught exception 'ReflectionException' with message 'Parameter 
is 
not optional' in test.php on line 12

ReflectionException: Parameter is not optional in test.php on line 12

Call Stack:
0.0010 646632   1. {main}() test.php:0
0.0011 651128   2. ReflectionParameter->getDefaultValue() test.php:12






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


Bug #61859 [Com]: pdo fails on make

2012-08-21 Thread paszczak000 at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=61859&edit=1

 ID: 61859
 Comment by: paszczak000 at gmail dot com
 Reported by:gencer at cmail dot cm
 Summary:pdo fails on make
 Status: Feedback
 Type:   Bug
 Package:Compile Failure
 Operating System:   CentOS 5.8 x86_64
 PHP Version:5.4.1
 Block user comment: N
 Private report: N

 New Comment:

The same result with: 5.4.6 on CentOS release 6.3 (Final).


Previous Comments:

[2012-06-16 09:01:29] paszczak000 at gmail dot com

The same error I have on CentOS release 6.2 (Final) - 
2.6.32-220.13.1.el6.centos.plus.x86_64.

./configure --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin 
--sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share 
--includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec 
--localstatedir=/var --sharedstatedir=/usr/com --mandir=/usr/share/man 
--infodir=/usr/share/info --cache-file=../config.cache --with-libdir=lib64 
--with-config-file-path=/etc --with-config-file-scan-dir=/etc/php.d 
--disable-debug --with-pic --disable-rpath --without-pear --with-bz2 
--with-curl --with-freetype-dir=/usr --with-gd --enable-gd-jis-conv 
--enable-gd-native-ttf --with-gdbm --with-gmp --enable-mbstring --with-iconv 
--with-jpeg-dir=/usr --with-pspell -with-zlib --with-zlib-dir=/usr/include 
--with-layout=GNU --enable-exif --enable-ftp --enable-sockets --enable-sysvsem 
--enable-sysvshm --enable-sysvmsg --enable-wddx --with-unixODBC=shared,/usr 
--enable-shmop --enable-calendar --without-sqlite3 --without-pdo-sqlite 
--with-libxml-dir=/usr --with-mhash --with-mcrypt --with-apxs2 --disable-dba 
--without-unixODBC --enable-json --with-mysql --with-mysqli --enable-soap 
--with-imap-ssl --with-imap --with-openssl --with-kerberos --enable-bcmath 
--with-pdo-mysql --with-pear=/usr/lib/php --with-gettext

But version PHP 5.4.1 with the same options in compiling very well.


[2012-05-01 06:44:14] gencer at cmail dot cm

Here is the full configure pattern:

'./configure' '--build=x86_64-redhat-linux-gnu' 
'--host=x86_64-redhat-linux-gnu' '--target=x86_64-redhat-linux-gnu' 
'--program-prefix=' '--prefix=/usr' '--exec-prefix=/usr' '--bindir=/usr/bin' 
'--sbindir=/usr/sbin' '--sysconfdir=/etc' '--datadir=/usr/share' 
'--includedir=/usr/include' '--libdir=/usr/lib64' '--libexecdir=/usr/libexec' 
'--localstatedir=/var' '--sharedstatedir=/usr/com' '--mandir=/usr/share/man' 
'--infodir=/usr/share/info' '--cache-file=../config.cache' 
'--with-libdir=lib64' '--with-config-file-path=/etc' 
'--with-config-file-scan-dir=/etc/php.d' '--disable-debug' '--with-pic' 
'--disable-rpath' '--without-pear' '--with-bz2' '--with-exec-dir=/usr/bin' 
'--with-freetype-dir=/usr' '--with-png-dir=/usr' '--with-xpm-dir=/usr' 
'--enable-gd-native-ttf' '--with-t1lib=/usr' '--without-gdbm' '--with-gettext' 
'--with-gmp' '--with-iconv' '--with-jpeg-dir=/usr' '--with-openssl' 
'--with-pcre-regex' '--with-zlib' '--with-layout=GNU' '--enable-exif' 
'--enable-ftp' '--enable-magic-quotes' '--enable-sockets' '--with-kerberos' 
'--enable-ucd-snmp-hack' '--enable-shmop' '--enable-calendar' 
'--with-libxml-dir=/usr' '--enable-libxml' '--with-xmlrpc' '--enable-xml' 
'--with-system-tzdata' '--with-mhash' '--with-mysql' '--with-gd' '--enable-dom' 
'--disable-dba' '--without-unixODBC--disable-xmlreader' '--disable-xmlwriter' 
'--without-sqlite' '--with-sqlite3' '--enable-phar' '--enable-fileinfo' 
'--enable-json' '--without-pspell' '--disable-wddx' '--without-curl' 
'--disable-posix' '--disable-sysvmsg' '--disable-sysvshm' '--disable-sysvsem' 
'--enable-pdo' '--enable-mbstring' '--enable-fastcgi' '--with-mcrypt' 
'--enable-fpm' '--with-mysqli=/usr/bin/mysql_config' '--with-pdo-mysql' 
'--enable-pcntl' '--with-imap=../imap/imap-2007f' '--with-imap-ssl' 
'--with-pgsql=/usr/pgsql-9.1' '--with-pdo-pgsql=/usr/pgsql-9.1'

Please allow me to remind this. This is not only for postgresql also pdo_mysql 
and pdo_sqlite too.

These errors happend to me after i updated/upgraded my linux system to the 
latest updates/versions. (like gcc, glibc etc.) All updates are stable and 
released by CentOS (but not by other 3rd parties).

Few weeks ago i havd no errors with this. But now i have.


[2012-04-30 21:08:17] s...@php.net

What were the original configure options (and other commands, if any) you used 
that produced the failure?


[2012-04-26 20:04:08] gencer at cmail dot cm

Switched to the Compile Failure.
Issue seems to be applied on all version of PHP 5.4 with updated CentOS 5.8.


[2012-04-26 19:55:49] gencer at cmail dot cm

Description:

PDO