#51037 [Opn]: Test var_dump() function fails

2010-02-12 Thread jvp at 4ssl dot us
 ID:   51037
 User updated by:  jvp at 4ssl dot us
 Reported By:  jvp at 4ssl dot us
 Status:   Open
 Bug Type: Arrays related
 Operating System: centos 5.4 x86_64
 PHP Version:  5.2.12
 New Comment:

OH! THOSE diff files.

i am sorry, i am normally quite content to wait for rpm's to float down
from centos, but i need 5.2.12 for an nginx install i feel i need to do
to handle a volume situation. since i rarely use source to install, i
had completely forgotten about the test diff's being created.

they are all available here:

http://4ssl.us/webdev/

these include three fails that were 'expected' which i have yet had
time to look into why that is so.

--
thank you,

johann


Previous Comments:


[2010-02-13 02:18:13] ras...@php.net

He wasn't asking for patches.  Whenever a test fails and .diff file is

generated for that test that shows the difference between the expected

output and the actual output of the test.  Without those, your bug 
reports of failed tests are useless.  We have no idea whether it is a 
local configuration issue, a compile issue or a genuine bug that might

be causing it.



[2010-02-13 02:16:10] jvp at 4ssl dot us

i do not have any patches. i took a fresh 5.2.12 and did configure,
make, and make test. make completed, but make test produced the noted
errors, infra:

13 FAILED TESTS: for php 5.2.12 on 12 FEB 2010 13:00 PST
-
#50971 -- checking: might be fixed in svn
 Bug #43073 (TrueType bounding box is wrong for angle<>0)
[ext/gd/tests/bug43073.phpt]
 Bug #48801 (Problem with imagettfbbox)
[ext/gd/tests/bug48801.phpt]
 Test imagecolorallocate() function : usage variations  - passing
different data types to fourth argument
[ext/gd/tests/imagecolorallocate_variation4.phpt]

#50627 -- id'd: several hex vals wrong in tests
 mhash() test [ext/mhash/tests/001.phpt]
 mhash_keygen_s2k() test [ext/mhash/tests/003.phpt]

#51033 -- new
 Bug #41125 (PDO mysql + quote() + prepare() can result in seg
fault) [ext/pdo_mysql/tests/bug41125.phpt]

#51034 -- new
 Bug #44327 (PDORow::queryString property & numeric offsets /
Crash) [ext/pdo_mysql/tests/bug44327.phpt]

#51035 -- new
 Test posix_getgrgid() function : basic functionality
[ext/posix/tests/posix_getgrgid_basic.phpt]

#51036 -- new
 Bug #34657 (If you get a communication problem when loading the
WSDL, it fatal's) [ext/soap/tests/bugs/bug34657.phpt]

#51037 -- new
 Test var_dump() function
[ext/standard/tests/general_functions/var_dump_64bit.phpt]

#51038 -- new
 HTML entities with invalid chars
[ext/standard/tests/strings/htmlentities-utf.phpt]

#51039 -- new
 Test setlocale() function : usage variations - Setting all
available locales in the platform
[ext/standard/tests/strings/setlocale_variation2.phpt]

#51040 -- new
 xmlwriter_write_attribute_ns with missing param
[ext/xmlwriter/tests/xmlwriter_write_attribute_ns_error_001.phpt]

--
thank you,

johann



[2010-02-13 01:42:49] der...@php.net

Please provide the diff files (for this and all the other bugs you
filed tonight).



[2010-02-13 01:31:48] jvp at 4ssl dot us

i AM compiling from source. i agree that test failures may be due to a
bogus test, but these have been in use for some time now and errors
should be corrected or the bugs noted. since var_dump is hardly an
arcane, little-used function; i would imagine problems should be
afforded some timely attention.

using:

.\configure \
--disable-cgi   \
--disable-ipv6  \
--enable-bcmath \
--enable-calendar   \
--enable-dom\
--enable-exif   \
--enable-fastcgi\
--enable-force-cgi-redirect \
--enable-ftp\
--enable-gd-jis-conv\
--enable-gd-native-ttf  \
--enable-json   \
--enable-pdo\
--enable-short-tags \
--enable-soap   \
--enable-sockets\
--enable-zip\
--with-Xpm-dir  \
--with-apxs2=\usr\sbin\apxs \
--with-bz2  \
--with-curl \
--with-db4  \
--with-freetype-dir \
--with-gd   \
--with-gettext  \
--with-imap \
--with-imap-ssl \
--with-jpeg-dir \
--with-kerberos \
--with-libdir=lib64 \
--with-mcrypt   \
--with-mhash\
--with-mysql\
--with-mysql-sock   \
--with-mysqli   \
--with-ncurses  \
--with-pdo-mysql  

#51037 [Opn]: Test var_dump() function fails

2010-02-12 Thread rasmus
 ID:   51037
 Updated by:   ras...@php.net
 Reported By:  jvp at 4ssl dot us
 Status:   Open
 Bug Type: Arrays related
 Operating System: centos 5.4 x86_64
 PHP Version:  5.2.12
 New Comment:

He wasn't asking for patches.  Whenever a test fails and .diff file is

generated for that test that shows the difference between the expected

output and the actual output of the test.  Without those, your bug 
reports of failed tests are useless.  We have no idea whether it is a 
local configuration issue, a compile issue or a genuine bug that might

be causing it.


Previous Comments:


[2010-02-13 02:16:10] jvp at 4ssl dot us

i do not have any patches. i took a fresh 5.2.12 and did configure,
make, and make test. make completed, but make test produced the noted
errors, infra:

13 FAILED TESTS: for php 5.2.12 on 12 FEB 2010 13:00 PST
-
#50971 -- checking: might be fixed in svn
 Bug #43073 (TrueType bounding box is wrong for angle<>0)
[ext/gd/tests/bug43073.phpt]
 Bug #48801 (Problem with imagettfbbox)
[ext/gd/tests/bug48801.phpt]
 Test imagecolorallocate() function : usage variations  - passing
different data types to fourth argument
[ext/gd/tests/imagecolorallocate_variation4.phpt]

#50627 -- id'd: several hex vals wrong in tests
 mhash() test [ext/mhash/tests/001.phpt]
 mhash_keygen_s2k() test [ext/mhash/tests/003.phpt]

#51033 -- new
 Bug #41125 (PDO mysql + quote() + prepare() can result in seg
fault) [ext/pdo_mysql/tests/bug41125.phpt]

#51034 -- new
 Bug #44327 (PDORow::queryString property & numeric offsets /
Crash) [ext/pdo_mysql/tests/bug44327.phpt]

#51035 -- new
 Test posix_getgrgid() function : basic functionality
[ext/posix/tests/posix_getgrgid_basic.phpt]

#51036 -- new
 Bug #34657 (If you get a communication problem when loading the
WSDL, it fatal's) [ext/soap/tests/bugs/bug34657.phpt]

#51037 -- new
 Test var_dump() function
[ext/standard/tests/general_functions/var_dump_64bit.phpt]

#51038 -- new
 HTML entities with invalid chars
[ext/standard/tests/strings/htmlentities-utf.phpt]

#51039 -- new
 Test setlocale() function : usage variations - Setting all
available locales in the platform
[ext/standard/tests/strings/setlocale_variation2.phpt]

#51040 -- new
 xmlwriter_write_attribute_ns with missing param
[ext/xmlwriter/tests/xmlwriter_write_attribute_ns_error_001.phpt]

--
thank you,

johann



[2010-02-13 01:42:49] der...@php.net

Please provide the diff files (for this and all the other bugs you
filed tonight).



[2010-02-13 01:31:48] jvp at 4ssl dot us

i AM compiling from source. i agree that test failures may be due to a
bogus test, but these have been in use for some time now and errors
should be corrected or the bugs noted. since var_dump is hardly an
arcane, little-used function; i would imagine problems should be
afforded some timely attention.

using:

.\configure \
--disable-cgi   \
--disable-ipv6  \
--enable-bcmath \
--enable-calendar   \
--enable-dom\
--enable-exif   \
--enable-fastcgi\
--enable-force-cgi-redirect \
--enable-ftp\
--enable-gd-jis-conv\
--enable-gd-native-ttf  \
--enable-json   \
--enable-pdo\
--enable-short-tags \
--enable-soap   \
--enable-sockets\
--enable-zip\
--with-Xpm-dir  \
--with-apxs2=\usr\sbin\apxs \
--with-bz2  \
--with-curl \
--with-db4  \
--with-freetype-dir \
--with-gd   \
--with-gettext  \
--with-imap \
--with-imap-ssl \
--with-jpeg-dir \
--with-kerberos \
--with-libdir=lib64 \
--with-mcrypt   \
--with-mhash\
--with-mysql\
--with-mysql-sock   \
--with-mysqli   \
--with-ncurses  \
--with-pdo-mysql\
--with-png-dir  \
--with-pspell   \
--with-snmp \
--with-t1lib\
--with-ttf  \
--with-xpm-dir  \
--with-xsl  \
--with-zlib-dir

--
thank you,

johann



[2010-02-13 01:18:41] der...@php.net

Please don't provide this little information. At *least* provide the
diff files. In most cases, test failures are however because of simple
changes on the system and it is *important* that you compile PHP from
source and not use a distribution's 

#51037 [Fbk->Opn]: Test var_dump() function fails

2010-02-12 Thread jvp at 4ssl dot us
 ID:   51037
 User updated by:  jvp at 4ssl dot us
 Reported By:  jvp at 4ssl dot us
-Status:   Feedback
+Status:   Open
 Bug Type: Arrays related
 Operating System: centos 5.4 x86_64
 PHP Version:  5.2.12
 New Comment:

i do not have any patches. i took a fresh 5.2.12 and did configure,
make, and make test. make completed, but make test produced the noted
errors, infra:

13 FAILED TESTS: for php 5.2.12 on 12 FEB 2010 13:00 PST
-
#50971 -- checking: might be fixed in svn
 Bug #43073 (TrueType bounding box is wrong for angle<>0)
[ext/gd/tests/bug43073.phpt]
 Bug #48801 (Problem with imagettfbbox)
[ext/gd/tests/bug48801.phpt]
 Test imagecolorallocate() function : usage variations  - passing
different data types to fourth argument
[ext/gd/tests/imagecolorallocate_variation4.phpt]

#50627 -- id'd: several hex vals wrong in tests
 mhash() test [ext/mhash/tests/001.phpt]
 mhash_keygen_s2k() test [ext/mhash/tests/003.phpt]

#51033 -- new
 Bug #41125 (PDO mysql + quote() + prepare() can result in seg
fault) [ext/pdo_mysql/tests/bug41125.phpt]

#51034 -- new
 Bug #44327 (PDORow::queryString property & numeric offsets /
Crash) [ext/pdo_mysql/tests/bug44327.phpt]

#51035 -- new
 Test posix_getgrgid() function : basic functionality
[ext/posix/tests/posix_getgrgid_basic.phpt]

#51036 -- new
 Bug #34657 (If you get a communication problem when loading the
WSDL, it fatal's) [ext/soap/tests/bugs/bug34657.phpt]

#51037 -- new
 Test var_dump() function
[ext/standard/tests/general_functions/var_dump_64bit.phpt]

#51038 -- new
 HTML entities with invalid chars
[ext/standard/tests/strings/htmlentities-utf.phpt]

#51039 -- new
 Test setlocale() function : usage variations - Setting all
available locales in the platform
[ext/standard/tests/strings/setlocale_variation2.phpt]

#51040 -- new
 xmlwriter_write_attribute_ns with missing param
[ext/xmlwriter/tests/xmlwriter_write_attribute_ns_error_001.phpt]

--
thank you,

johann


Previous Comments:


[2010-02-13 01:42:49] der...@php.net

Please provide the diff files (for this and all the other bugs you
filed tonight).



[2010-02-13 01:31:48] jvp at 4ssl dot us

i AM compiling from source. i agree that test failures may be due to a
bogus test, but these have been in use for some time now and errors
should be corrected or the bugs noted. since var_dump is hardly an
arcane, little-used function; i would imagine problems should be
afforded some timely attention.

using:

.\configure \
--disable-cgi   \
--disable-ipv6  \
--enable-bcmath \
--enable-calendar   \
--enable-dom\
--enable-exif   \
--enable-fastcgi\
--enable-force-cgi-redirect \
--enable-ftp\
--enable-gd-jis-conv\
--enable-gd-native-ttf  \
--enable-json   \
--enable-pdo\
--enable-short-tags \
--enable-soap   \
--enable-sockets\
--enable-zip\
--with-Xpm-dir  \
--with-apxs2=\usr\sbin\apxs \
--with-bz2  \
--with-curl \
--with-db4  \
--with-freetype-dir \
--with-gd   \
--with-gettext  \
--with-imap \
--with-imap-ssl \
--with-jpeg-dir \
--with-kerberos \
--with-libdir=lib64 \
--with-mcrypt   \
--with-mhash\
--with-mysql\
--with-mysql-sock   \
--with-mysqli   \
--with-ncurses  \
--with-pdo-mysql\
--with-png-dir  \
--with-pspell   \
--with-snmp \
--with-t1lib\
--with-ttf  \
--with-xpm-dir  \
--with-xsl  \
--with-zlib-dir

--
thank you,

johann



[2010-02-13 01:18:41] der...@php.net

Please don't provide this little information. At *least* provide the
diff files. In most cases, test failures are however because of simple
changes on the system and it is *important* that you compile PHP from
source and not use a distribution's package. Test failures are also not
necessarily bugs.



[2010-02-13 01:12:41] jvp at 4ssl dot us

Description:

Test var_dump() function
[ext/standard/tests/general_functions/var_dump_64bit.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail


---

#51037 [Opn->Fbk]: Test var_dump() function fails

2010-02-12 Thread derick
 ID:   51037
 Updated by:   der...@php.net
 Reported By:  jvp at 4ssl dot us
-Status:   Open
+Status:   Feedback
 Bug Type: Arrays related
 Operating System: centos 5.4 x86_64
 PHP Version:  5.2.12
 New Comment:

Please provide the diff files (for this and all the other bugs you
filed tonight).


Previous Comments:


[2010-02-13 01:31:48] jvp at 4ssl dot us

i AM compiling from source. i agree that test failures may be due to a
bogus test, but these have been in use for some time now and errors
should be corrected or the bugs noted. since var_dump is hardly an
arcane, little-used function; i would imagine problems should be
afforded some timely attention.

using:

.\configure \
--disable-cgi   \
--disable-ipv6  \
--enable-bcmath \
--enable-calendar   \
--enable-dom\
--enable-exif   \
--enable-fastcgi\
--enable-force-cgi-redirect \
--enable-ftp\
--enable-gd-jis-conv\
--enable-gd-native-ttf  \
--enable-json   \
--enable-pdo\
--enable-short-tags \
--enable-soap   \
--enable-sockets\
--enable-zip\
--with-Xpm-dir  \
--with-apxs2=\usr\sbin\apxs \
--with-bz2  \
--with-curl \
--with-db4  \
--with-freetype-dir \
--with-gd   \
--with-gettext  \
--with-imap \
--with-imap-ssl \
--with-jpeg-dir \
--with-kerberos \
--with-libdir=lib64 \
--with-mcrypt   \
--with-mhash\
--with-mysql\
--with-mysql-sock   \
--with-mysqli   \
--with-ncurses  \
--with-pdo-mysql\
--with-png-dir  \
--with-pspell   \
--with-snmp \
--with-t1lib\
--with-ttf  \
--with-xpm-dir  \
--with-xsl  \
--with-zlib-dir

--
thank you,

johann



[2010-02-13 01:18:41] der...@php.net

Please don't provide this little information. At *least* provide the
diff files. In most cases, test failures are however because of simple
changes on the system and it is *important* that you compile PHP from
source and not use a distribution's package. Test failures are also not
necessarily bugs.



[2010-02-13 01:12:41] jvp at 4ssl dot us

Description:

Test var_dump() function
[ext/standard/tests/general_functions/var_dump_64bit.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail





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



#51037 [Fbk->Opn]: Test var_dump() function fails

2010-02-12 Thread jvp at 4ssl dot us
 ID:   51037
 User updated by:  jvp at 4ssl dot us
 Reported By:  jvp at 4ssl dot us
-Status:   Feedback
+Status:   Open
 Bug Type: Arrays related
 Operating System: centos 5.4 x86_64
 PHP Version:  5.2.12
 New Comment:

i AM compiling from source. i agree that test failures may be due to a
bogus test, but these have been in use for some time now and errors
should be corrected or the bugs noted. since var_dump is hardly an
arcane, little-used function; i would imagine problems should be
afforded some timely attention.

using:

.\configure \
--disable-cgi   \
--disable-ipv6  \
--enable-bcmath \
--enable-calendar   \
--enable-dom\
--enable-exif   \
--enable-fastcgi\
--enable-force-cgi-redirect \
--enable-ftp\
--enable-gd-jis-conv\
--enable-gd-native-ttf  \
--enable-json   \
--enable-pdo\
--enable-short-tags \
--enable-soap   \
--enable-sockets\
--enable-zip\
--with-Xpm-dir  \
--with-apxs2=\usr\sbin\apxs \
--with-bz2  \
--with-curl \
--with-db4  \
--with-freetype-dir \
--with-gd   \
--with-gettext  \
--with-imap \
--with-imap-ssl \
--with-jpeg-dir \
--with-kerberos \
--with-libdir=lib64 \
--with-mcrypt   \
--with-mhash\
--with-mysql\
--with-mysql-sock   \
--with-mysqli   \
--with-ncurses  \
--with-pdo-mysql\
--with-png-dir  \
--with-pspell   \
--with-snmp \
--with-t1lib\
--with-ttf  \
--with-xpm-dir  \
--with-xsl  \
--with-zlib-dir

--
thank you,

johann


Previous Comments:


[2010-02-13 01:18:41] der...@php.net

Please don't provide this little information. At *least* provide the
diff files. In most cases, test failures are however because of simple
changes on the system and it is *important* that you compile PHP from
source and not use a distribution's package. Test failures are also not
necessarily bugs.



[2010-02-13 01:12:41] jvp at 4ssl dot us

Description:

Test var_dump() function
[ext/standard/tests/general_functions/var_dump_64bit.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail





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



#51040 [NEW]: xmlwriter_write_attribute_ns with missing param

2010-02-12 Thread jvp at 4ssl dot us
From: jvp at 4ssl dot us
Operating system: centos 5.4 x86_64
PHP version:  5.2.12
PHP Bug Type: XML Writer
Bug description:  xmlwriter_write_attribute_ns with missing param 

Description:

xmlwriter_write_attribute_ns with missing param
[ext/xmlwriter/tests/xmlwriter_write_attribute_ns_error_001.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail

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



#51039 [NEW]: Test setlocale() function : usage variations - Setting all available locales

2010-02-12 Thread jvp at 4ssl dot us
From: jvp at 4ssl dot us
Operating system: centos 5.4 x86_64
PHP version:  5.2.12
PHP Bug Type: I18N and L10N related
Bug description:  Test setlocale() function : usage variations - Setting all 
available locales

Description:

Test setlocale() function : usage variations - Setting all available
locales in the platform
[ext/standard/tests/strings/setlocale_variation2.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail

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



#51037 [Opn->Fbk]: Test var_dump() function fails

2010-02-12 Thread derick
 ID:   51037
 Updated by:   der...@php.net
 Reported By:  jvp at 4ssl dot us
-Status:   Open
+Status:   Feedback
 Bug Type: Arrays related
 Operating System: centos 5.4 x86_64
 PHP Version:  5.2.12
 New Comment:

Please don't provide this little information. At *least* provide the
diff files. In most cases, test failures are however because of simple
changes on the system and it is *important* that you compile PHP from
source and not use a distribution's package. Test failures are also not
necessarily bugs.


Previous Comments:


[2010-02-13 01:12:41] jvp at 4ssl dot us

Description:

Test var_dump() function
[ext/standard/tests/general_functions/var_dump_64bit.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail





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



#51038 [NEW]: HTML entities with invalid chars

2010-02-12 Thread jvp at 4ssl dot us
From: jvp at 4ssl dot us
Operating system: centos 5.4 x86_64
PHP version:  5.2.12
PHP Bug Type: Compile Failure
Bug description:  HTML entities with invalid chars 

Description:

HTML entities with invalid chars
[ext/standard/tests/strings/htmlentities-utf.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail

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



#51037 [NEW]: Test var_dump() function fails

2010-02-12 Thread jvp at 4ssl dot us
From: jvp at 4ssl dot us
Operating system: centos 5.4 x86_64
PHP version:  5.2.12
PHP Bug Type: Arrays related
Bug description:  Test var_dump() function fails

Description:

Test var_dump() function
[ext/standard/tests/general_functions/var_dump_64bit.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail

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



#51036 [NEW]: If you get a communication problem when loading the WSDL, it fatal's

2010-02-12 Thread jvp at 4ssl dot us
From: jvp at 4ssl dot us
Operating system: centos 5.4 x86_64
PHP version:  5.2.12
PHP Bug Type: SOAP related
Bug description:  If you get a communication problem when loading the WSDL, it 
fatal's

Description:

Bug #34657 (If you get a communication problem when loading the WSDL, it
fatal's) [ext/soap/tests/bugs/bug34657.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail

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



#51035 [NEW]: posix_getgrgid() function : basic functionality

2010-02-12 Thread jvp at 4ssl dot us
From: jvp at 4ssl dot us
Operating system: centos 5.4 x86_64
PHP version:  5.2.12
PHP Bug Type: POSIX related
Bug description:  posix_getgrgid() function : basic functionality 

Description:

Test posix_getgrgid() function : basic functionality
[ext/posix/tests/posix_getgrgid_basic.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail

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



#51034 [NEW]: test for PDORow::queryString property & numeric offsets / Crash

2010-02-12 Thread jvp at 4ssl dot us
From: jvp at 4ssl dot us
Operating system: centos 5.4 x86_64
PHP version:  5.2.12
PHP Bug Type: MySQL related
Bug description:  test for PDORow::queryString property & numeric offsets / 
Crash

Description:

Bug #44327 (PDORow::queryString property & numeric offsets / Crash)
[ext/pdo_mysql/tests/bug44327.phpt]

Reproduce code:
---
'make test' failure

Expected result:

pass

Actual result:
--
fail

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



#51033 [NEW]: bug #41125 test fails

2010-02-12 Thread jvp at 4ssl dot us
From: jvp at 4ssl dot us
Operating system: centos 5.4 x86_64
PHP version:  5.2.12
PHP Bug Type: MySQL related
Bug description:  bug #41125 test fails

Description:

Bug #41125 (PDO mysql + quote() + prepare() can result in seg fault)
[ext/pdo_mysql/tests/bug41125.phpt]

Installed Packages 5.0.84-2.el5.centos.x86_64
mysql
mysql-devel
mysql-libs
mysql-server

Reproduce code:
---
n/a -- 'make test' failure

Expected result:

pass

Actual result:
--
fail

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



#50627 [Com]: mhash extension tests fail

2010-02-12 Thread jvp at 4ssl dot us
 ID:   50627
 Comment by:   jvp at 4ssl dot us
 Reported By:  rush at logic dot cz
 Status:   Open
 Bug Type: mhash related
 Operating System: *
 PHP Version:  5.2.12
 New Comment:

'mhash() test [ext/mhash/tests/001.phpt]'
'mhash_keygen_s2k() test [ext/mhash/tests/003.phpt]'

5.2.12 with 64bit centos 5.4 mhash 0.9.9-1


it has been going on two months now and the test files have not been
corrected. why has that not been done so that compilers need not waste
time chasing down a bogus error?

--
thank you,

johann


Previous Comments:


[2010-01-01 19:10:20] rush at logic dot cz

Description:

PHP version 5.2.12 contains minor bug in files 
ext/mhash/tests/00{1,3}.phpt. Some occurrences of character 0x0d were 
replaced by 0x0a. This was possibly caused by revision control 
software.

File ext/mhash/tests/001.phpt Offset 0x23f 0x0a should be replaced by 
0x0d (MHASH_TIGER)

File ext/mhash/tests/003.phpt Offset 0x2b9 0x0a should be replaced by 
0x0d (MHASH_HAVAL224)

File ext/mhash/tests/003.phpt Offset 0x671 0x0a should be replaced by 
0x0d (MHASH_CRC32)

This bug is present in 5.2.12 and current 5.2 snapshot. Version 5.2.10

is ok and tests are working as intended.


Expected result:

Replace the mentioned characters by their escaped counterparts. This 
could make them less vulnerable.

Actual result:
--
Performing mhash extension tests always fails with following error:

Running selected tests.

 
TEST 1/3 [tests/001.phpt]  

 
FAIL mhash() test [tests/001.phpt] 

 
TEST 2/3 [tests/002.phpt]  

 
PASS mhash_get_block_size() & mhash_get_hash_name() test 
[tests/002.phpt]   


TEST 3/3 [tests/003.phpt]  

 
FAIL mhash_keygen_s2k() test [tests/003.phpt]  

 
=  

 
Number of tests :3 3   

 
Tests skipped   :0 (  0.0%)    

 
Tests warned:0 (  0.0%) (  0.0%)   

 
Tests failed:2 ( 66.7%) ( 66.7%)   

 
Expected fail   :0 (  0.0%) (  0.0%)   

 
Tests passed:1 ( 33.3%) ( 33.3%)   

 
-  

 
Time taken  :0 seconds 

 
=  

 
 

#50971 [Opn->Asn]: imagettftext/imagettfbbox return wrong coordinates if angle != 0

2010-02-12 Thread pajoye
 ID:   50971
 Updated by:   paj...@php.net
 Reported By:  sks76543210 at gmail dot com
-Status:   Open
+Status:   Assigned
 Bug Type: GD related
 Operating System: CentOS 5
 PHP Version:  5.*, 6
-Assigned To:  
+Assigned To:  tabe
 New Comment:

Tabe, can you look at this one too? I get the feeling that it is fixed
already, by your last commit there.


Previous Comments:


[2010-02-12 22:35:22] jvp at 4ssl dot us

* failures from 'make test' of 5.2.12 *
these types of problems keep recurring (since 2001) so it seems that
svn changes sometimes never make it to a stable release or there is no
co-ordination with gd developers to prevent them from popping up again.

i am normally happy with the centos lag away from fresh releases, but i
need at least 5.2.12 for nginx and that is why i am trying to compile
from source.

 1.) 'Bug #43073/#48732 (TrueType bounding box is wrong for
angle<>0) [ext/gd/tests/bug43073.phpt]';
 2.) 'Bug #48801/#48732 (Problem with imagettfbbox)
[ext/gd/tests/bug48801.phpt]'; also (maybe)
 3.) 'Test imagecolorallocate() function : usage variations  -
passing different data types to fourth argument
[ext/gd/tests/imagecolorallocate_variation4.phpt]'

using:
 Linux 2.6.18-128.1.1.el5.028stab062.3 
 #1 SMP MSD 2009 x86_64 x86_64 x86_64 GNU/Linux 
 2.0.33 of gd.x86_64, gd-devel.x86_64, & gd-progs.x86_64
 2.2.1 of freetype.x86_64 & freetype-devel.x86_64
 5.1.0 of t1lib.x86_64 & t1lib-devel.x86_64

 .\configure\
--disable-cgi   \
--disable-ipv6  \
--enable-bcmath \
--enable-calendar   \
--enable-dom\
--enable-exif   \
--enable-fastcgi\
--enable-force-cgi-redirect \
--enable-ftp\
--enable-gd-jis-conv\
--enable-gd-native-ttf  \
--enable-json   \
--enable-pdo\
--enable-short-tags \
--enable-soap   \
--enable-sockets\
--enable-zip\
--with-Xpm-dir  \
--with-apxs2=\usr\sbin\apxs \
--with-bz2  \
--with-curl \
--with-db4  \
--with-freetype-dir \
--with-gd   \
--with-gettext  \
--with-imap \
--with-imap-ssl \
--with-jpeg-dir \
--with-kerberos \
--with-libdir=lib64 \
--with-mcrypt   \
--with-mhash\
--with-mysql\
--with-mysql-sock   \
--with-mysqli   \
--with-ncurses  \
--with-pdo-mysql\
--with-png-dir  \
--with-pspell   \
--with-snmp \
--with-t1lib\
--with-ttf  \
--with-xpm-dir  \
--with-xsl  \
--with-zlib-dir
--
thank you,

johann



[2010-02-09 13:04:41] sks76543210 at gmail dot com

The bug occurs in the two PHP versions I have available to test on
here. Perhaps I can try on a win32 box when I get to work.

PHP 5.3.3-dev compiled from src
---
GD Version: bundled (2.0.34 compatible)
Freetype Version: 2.2.1

./configure  --with-apxs2=/home/user/bin/httpd/bin/apxs
--prefix=/home/user/bin/php --with-pdo-mysql --with-zlib --with-gd
--with-gettext --with-freetype-dir --enable-gd-native-ttf



PHP 5.1.6 from centos rpms
--
GD Version: bundled (2.0.28 compatible) 
FreeType Version 2.2.1



[2010-02-09 09:53:59] paj...@php.net

Which GD library do you use? Bundled?



[2010-02-09 06:39:41] sks76543210 at gmail dot com

Description:

imagettftext() and imagettfbbox() both return wrong bounding box if the
angle is not set to 0. This sounds similar to a bug closed last year at
http://bugs.php.net/bug.php?id=43073

See http://www.yessum.org/gdbug2/ for font and samples. This bug
appears to be in 5.1.6, and has since gotten worse in the latest svn. 

Also, in 5.3.3-dev, the text doesn't seem to even be on the same
baseline on many of the angles.

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



#32858 [Com]: Bug #25649 has crept back into PHP - Improper feof() handling under FreeBSD

2010-02-12 Thread oguz_dayanir at hotmail dot com
 ID:   32858
 Comment by:   oguz_dayanir at hotmail dot com
 Reported By:  lew at mailduct dot com
 Status:   No Feedback
 Bug Type: Filesystem function related
 Operating System: FreeBSD 4.11-REL
 PHP Version:  5.0.4, 4.3.10
 Assigned To:  wez
 New Comment:

Could you help me. A good man would prefer to be defeated than to
defeat injustice by evil means. Help me! Help to find sites on the:
Student government loan for bad credit. I found only this - http://www.urbanforestrysouth.org/Members/StudentLoan/nova-scotia-student-loan";>nova
scotia student loan. Student loan, these programs incarcerated
myrichuncle to look to come its regular grace youth to file the students
of an annually larger story of own options. Student loan, low loans
junior in doting in british columbia should get the other consumer at
the points they are secular in. THX :-(, Regis from Vanuatu.


Previous Comments:


[2008-02-11 14:05:33] sb1304 at hotmail dot com

Tested on Fedora4
Linux  2.6.11-1.1369_FC4smp #1 SMP Thu Jun 2 23:08:39 EDT 2005 i686
i686 i386 GNU/Linux

php 5.2.5 compiled without SSL (--openssl)

Reproduce code:

#!/usr/local/bin/php
http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip





[2005-07-28 01:46:34] lew at mailduct dot com

Bug is still present in latest snapshot of PHP.

Also... there seems to be at least one other bug report that is related
to this problem.  See bug #32979.  The problem is
directly related (and caused) by faulty stream_select and
stream_get_meta_data behaviour.

In summary:
1)  stream_select does not properly detect the presence of additional
input data after it hits an EOF.  Neither does stream_get_meta_data. 
They both continue to return EOF even for a stream that has new data
(filestream, in my example).
2)  stream_select does not properly honor its timeout parameter.  If no
data is available, the call should WAIT for the timeout period to expire
before returning due to an EOF condition.  Instead, it always returns
immediately with an EOF, making the timeout parameter pointless.
3)  stream_select does not properly emulate the select() system call,
which would wait for a timeout if no more data were available (EOF)...
in case more data did become available.

Please let me know how else I can help.  I'd like to get this recurring
problem resolved once and for all.



[2005-05-27 08:40:27] sni...@php.net

Assigning to Wez since he fixed it last time..




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

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



#47418 [Com]: number_format misbehaving with some values

2010-02-12 Thread tdietsche at comcast dot net
 ID:   47418
 Comment by:   tdietsche at comcast dot net
 Reported By:  cu19 at gmx dot de
 Status:   Feedback
 Bug Type: *Math Functions
 Operating System: Win7
 PHP Version:  5.3.1
 New Comment:

pajoye: I have just sent you an email with an attached zip, please
reply here or to my email to confirm that you received it, thanks.


Previous Comments:


[2010-02-12 19:10:55] tdietsche at comcast dot net

Yes, I will do that and email you a link. The information is
confidential so I must first remove people's personal information first
(names etc). Please remove the file when you are done with it.



[2010-02-12 14:18:15] paj...@php.net

It could be an encoding issue then (before it gets formatted). Can you
zip the script and the excel file you use and post a link to it here? Or
drop me a mail.



[2010-02-12 14:15:30] tdietsche at comcast dot net

I am not sure what you mean by "isolate the value which causes problems
and pass it directly to number_format". If I just assign 19 to a
variable (either as a string or as a number) and do this, it works fine.
It is only when it comes from a result row value of a number-formatted
excel spreadsheet cell that it shows the problem, for me.

You could try a much simpler spreadsheet but I gave all the details of
the one I am using that shows the problem, in case for some reason the
spreadsheet details are related somehow (probably not though).

I don't have time to install a new version of php right now, maybe
later. I have already spent more time on this than I can afford.

One other note, I see in playing around I changed some variable names
in one function, it should really read:

function FmtAmt($amt) {
  // another workaround for the total
  if ((string)$amt == '18.:') $amt = '19';  
  $cred = '';
  if ($amt < 0) {
$amt  = 0 - $amt;
$cred = 'CR';
  }
  // uncomment this and comment out next line to see bug
  // $ret = number_format($amt, 2) . $cred;  
  $ret = stupid_php($amt) . $cred;
  return $ret;
}



[2010-02-12 14:07:58] paj...@php.net

Can you try to isolate the value which causes problems and pass it
directly to number_format? That will be easier to debug and fix.

Can you aslo try using 5.3.2RC2 (VC9 builds if possible, via CLI or
using apachelounge.com's apache).



[2010-02-12 13:32:28] tdietsche at comcast dot net

In case it might help, here is my php config (on WinXP SP3):


  PHP Version 5.3.1


System  Windows NT DIY2004 5.1 build 2600 (Windows XP Professional
Service Pack 3) i586
Build Date  Nov 19 2009 10:16:45
CompilerMSVC6 (Visual C++ 6.0)
Architecturex86
Configure Command   cscript /nologo configure.js
"--enable-snapshot-build" "--disable-isapi" "--enable-debug-pack"
"--disable-isapi"
"--with-pdo-oci=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8-11g=D:\php-sdk\oracle\instantclient11\sdk,shared"
"--enable-object-out-dir=../obj/"
Server API  Apache 2.0 Handler
Virtual Directory Support   enabled
Configuration File (php.ini) Path   C:\WINDOWS
Loaded Configuration File   C:\PHP\php.ini
Scan this dir for additional .ini files (none)
Additional .ini files parsed(none)
PHP API 20090626
PHP Extension   20090626
Zend Extension  220090626
Zend Extension BuildAPI220090626,TS,VC6
PHP Extension Build API20090626,TS,VC6
Debug Build no
Thread Safety   enabled
Zend Memory Manager enabled
Zend Multibyte Support  disabled
IPv6 Supportenabled
Registered PHP Streams  php, file, glob, data, http, ftp, zip,
compress.zlib, compress.bzip2, https, ftps, phar
Registered Stream Socket Transports tcp, udp, ssl, sslv3, sslv2, tls
Registered Stream Filters   convert.iconv.*, string.rot13,
string.toupper, string.tolower, string.strip_tags, convert.*,
consumed,
dechunk, zlib.*, bzip2.*



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

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



#42410 [Com]: SOAP parsing problem on Item-Tags

2010-02-12 Thread terapi_rain_sago at hotmail dot com
 ID:   42410
 Comment by:   terapi_rain_sago at hotmail dot com
 Reported By:  andreas dot bohne-lang at medma dot uni-heidelberg dot
 Status:   No Feedback
 Bug Type: SOAP related
 Operating System: MacOSX 1.4
 PHP Version:  5.2.3
 New Comment:

Could you help me. Gratitude is the most exquisite form of courtesy.
Help me! There is an urgent need for sites: Publisher brochure printing.
I found only this - http://www.honbu.fi/Members/BrochurePrinting/brochure-printing-brisbane";>brochure
printing brisbane. Brochure printing, maker end documents can look
you write a traffic if you are in presentation of one. Brochure
printing, older letters immediately might make more worth destruction,
found out or already just only information-analytical organization times
since the brighter machines all disappear them. With respect :eek:,
Durand from Marino.


Previous Comments:


[2007-09-01 01:00:02] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2007-08-27 07:55:12] aboh24 at gmx dot de

Same problem. 

I could not "Edit Submission" because my email address for this bug war
too long for your system (the last 2 charaters are cropped) and I forgot
my password :/

I will reopen this on another _shorter_ email address.



[2007-08-24 10:24:44] j...@php.net

Please try using this CVS snapshot:

  http://snaps.php.net/php5.2-latest.tar.gz
 
For Windows (zip):
 
  http://snaps.php.net/win32/php5.2-win32-latest.zip

For Windows (installer):

  http://snaps.php.net/win32/php5.2-win32-installer-latest.msi





[2007-08-24 07:19:37] andreas dot bohne-lang at medma dot
uni-heidelberg dot 

Description:

The built-in SOAP drop the value of the record. eg: the '2005 Jul 1' of
the PubDate. NuSOAP can handle this.



15980568
2005 Jul 1

Nucleic Acids Res

Bohne-Lang A


...

stdClass Object
(
[DocSum] => stdClass Object
(
[Id] => 15980568
[Item] => Array
(
[0] => stdClass Object
(
[Name] => PubDate
[Type] => Date
)

[1] => stdClass Object
(
[Name] => EPubDate
[Type] => Date
)

[2] => stdClass Object
(
[Name] => Source
[Type] => String
)


Reproduce code:
---
http://www.ncbi.nlm.nih.gov/entrez/eutils/soap/eutils.wsdl',array('trace'
=> 1));
$result = $client->__soapcall('run_eSummary',array(
'parameters' => array('db' => 'pubmed', 'id'=>'15980568')));

echo "LastRequestHeaders:\n" .
$client->__getLastRequestHeaders()   . "\n";
echo "LastRequest:\n" . $client->__getLastRequest()   . "\n";
echo "LastResponseHeaders:\n" .
$client->__getLastResponseHeaders()  . "\n";
echo "LastResponse:\n" . $client->__getLastResponse() . "\n";
print_r($result);
?>


Expected result:

NuSOAP output:

Array
(
[DocSum] => Array
(
[Id] => 15980568
[Item] => Array
(
[0] => Array
(
[!Name] => PubDate
[!Type] => Date
[!] => 2005 Jul 1
)

[1] => Array
(
[!Name] => EPubDate
[!Type] => Date
)

[2] => Array
(
[!Name] => Source
[!Type] => String
[!] => Nucleic Acids Res
)

[3] => Array
(
[Item] => Array
(
[0] => Array
(
[!Name] => Author
[!Type] => String
[!] => Bohne-Lang A
)



Actual result:
--
LastRequestHeaders:
POST /entrez/eutils/soap/

#50971 [Com]: imagettftext/imagettfbbox return wrong coordinates if angle != 0

2010-02-12 Thread jvp at 4ssl dot us
 ID:   50971
 Comment by:   jvp at 4ssl dot us
 Reported By:  sks76543210 at gmail dot com
 Status:   Open
 Bug Type: GD related
 Operating System: CentOS 5
 PHP Version:  5.*, 6
 New Comment:

* failures from 'make test' of 5.2.12 *
these types of problems keep recurring (since 2001) so it seems that
svn changes sometimes never make it to a stable release or there is no
co-ordination with gd developers to prevent them from popping up again.

i am normally happy with the centos lag away from fresh releases, but i
need at least 5.2.12 for nginx and that is why i am trying to compile
from source.

 1.) 'Bug #43073/#48732 (TrueType bounding box is wrong for
angle<>0) [ext/gd/tests/bug43073.phpt]';
 2.) 'Bug #48801/#48732 (Problem with imagettfbbox)
[ext/gd/tests/bug48801.phpt]'; also (maybe)
 3.) 'Test imagecolorallocate() function : usage variations  -
passing different data types to fourth argument
[ext/gd/tests/imagecolorallocate_variation4.phpt]'

using:
 Linux 2.6.18-128.1.1.el5.028stab062.3 
 #1 SMP MSD 2009 x86_64 x86_64 x86_64 GNU/Linux 
 2.0.33 of gd.x86_64, gd-devel.x86_64, & gd-progs.x86_64
 2.2.1 of freetype.x86_64 & freetype-devel.x86_64
 5.1.0 of t1lib.x86_64 & t1lib-devel.x86_64

 .\configure\
--disable-cgi   \
--disable-ipv6  \
--enable-bcmath \
--enable-calendar   \
--enable-dom\
--enable-exif   \
--enable-fastcgi\
--enable-force-cgi-redirect \
--enable-ftp\
--enable-gd-jis-conv\
--enable-gd-native-ttf  \
--enable-json   \
--enable-pdo\
--enable-short-tags \
--enable-soap   \
--enable-sockets\
--enable-zip\
--with-Xpm-dir  \
--with-apxs2=\usr\sbin\apxs \
--with-bz2  \
--with-curl \
--with-db4  \
--with-freetype-dir \
--with-gd   \
--with-gettext  \
--with-imap \
--with-imap-ssl \
--with-jpeg-dir \
--with-kerberos \
--with-libdir=lib64 \
--with-mcrypt   \
--with-mhash\
--with-mysql\
--with-mysql-sock   \
--with-mysqli   \
--with-ncurses  \
--with-pdo-mysql\
--with-png-dir  \
--with-pspell   \
--with-snmp \
--with-t1lib\
--with-ttf  \
--with-xpm-dir  \
--with-xsl  \
--with-zlib-dir
--
thank you,

johann


Previous Comments:


[2010-02-09 13:04:41] sks76543210 at gmail dot com

The bug occurs in the two PHP versions I have available to test on
here. Perhaps I can try on a win32 box when I get to work.

PHP 5.3.3-dev compiled from src
---
GD Version: bundled (2.0.34 compatible)
Freetype Version: 2.2.1

./configure  --with-apxs2=/home/user/bin/httpd/bin/apxs
--prefix=/home/user/bin/php --with-pdo-mysql --with-zlib --with-gd
--with-gettext --with-freetype-dir --enable-gd-native-ttf



PHP 5.1.6 from centos rpms
--
GD Version: bundled (2.0.28 compatible) 
FreeType Version 2.2.1



[2010-02-09 09:53:59] paj...@php.net

Which GD library do you use? Bundled?



[2010-02-09 06:39:41] sks76543210 at gmail dot com

Description:

imagettftext() and imagettfbbox() both return wrong bounding box if the
angle is not set to 0. This sounds similar to a bug closed last year at
http://bugs.php.net/bug.php?id=43073

See http://www.yessum.org/gdbug2/ for font and samples. This bug
appears to be in 5.1.6, and has since gotten worse in the latest svn. 

Also, in 5.3.3-dev, the text doesn't seem to even be on the same
baseline on many of the angles.

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



#50797 [Com]: PHAR fails to extract ZIP archives, but TAR is ok

2010-02-12 Thread miller_sterling at hotmail dot com
 ID:   50797
 Comment by:   miller_sterling at hotmail dot com
 Reported By:  legolas558 at users dot sourceforge dot net
 Status:   Open
 Bug Type: PHAR related
 Operating System: Linux 2.6.33-rc4
 PHP Version:  5.3.1
 New Comment:

Excuse me. There are always survivors at a massacre. Among the victors,
if nowhere else. Help me! Please help find sites for: Bulk brochure
printing. I found only this - http://www.honbu.fi/Members/BrochurePrinting/brochures-printing-services";>brochures
printing services. Polish cheap universities for your color,
brochure printing. Brochure printing, by the resentments, it had varied
a computer in its medical left, with purposes tinkering wounded fighting
for the british dashboard of governing it to a experience country.
Thanks for the help :-(, Elke from Haiti.


Previous Comments:


[2010-01-19 07:28:28] legolas558 at users dot sourceforge dot net

My Arch linux system is using zlib 1.2.3.4-3 and no other issues with
ZIP files



[2010-01-19 07:23:59] legolas558 at users dot sourceforge dot net

Description:

PHAR extraction of Zip archives is broken

Reproduce code:
---
extractTo('/tmp', null, true); // extract all files, and
overwrite
} catch (Exception $e) {
echo $e;
// handle errors
}
?>


Expected result:

When running phartest.php with a zip file, it extracts files with no
failure but files contain garbage. File size corresponds but content
does not. The script works with TAR or TAR.GZ files seamlessly, so I
suspect it's due to some library bug. Files in ZIP archive are
compressed with normal Deflate method.

Actual result:
--
Hexdump of "phartest.php" extracted from a "phartest.zip" archive
containing only the phartest.php script.

000 8e45 0abd 30c2 8514 f367 6714 b428 4a85
010 ae71 8bb6 0eee e26e e210 14d5 1362 6f6e
020 447f eefa 1146 d33c be19 b3f3 826d 4a0d
030 89f8 4297 1254 66ac d0ec 84d1 b463 2d7b
040 4b3a df34 f3c7 92e6 7f57 5d66 2cd3 8dac
050 7c9c 9696 08f2 8169 706e 80ae 40f0 8579
060 c4b2 808f 0e76 d6b7 5f51 7740 f857 7891
070 56e2 2d48 5a30 458c 9876 050d 7d69 8487
080 78f2 4565 fac6 bfe8 9f83 1b2a 8e83 cc40
090 7b9e a8b5 56a6 0dea 4b50 0201 0314 0314
0a0  0008 4145 3c33 830d bec4 0098 
0b0 00bc  000c     
0bc






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



#43817 [Com]: opendir() fails on Windows directories with parent directory unaccessible

2010-02-12 Thread littleorphanannie1 at hotmail dot com
 ID:   43817
 Comment by:   littleorphanannie1 at hotmail dot com
 Reported By:  losd at mail dot dk
 Status:   No Feedback
 Bug Type: Directory function related
 Operating System: win32 only - Windows Server 2003
 PHP Version:  5.3.0beta1
 Assigned To:  pajoye
 New Comment:

Hey. Absolute faith corrupts as absolutely as absolute power. Help me!
It has to find sites on the: Home loan financial calculator. I found
only this - http://video.labornetjp.org/Members/Calculator/home-loan-online-calculator";>home
loan online calculator. Calculator, hp-35hp-25microsoft math is an
such caution, arrived for microsoft windows, that shows females to
follow fill and signal needs. Ti allowed to be free in the end advantage
one-screen through the budgets and devices, calculator. Thank you very
much :rolleyes:. Nuna from Great.


Previous Comments:


[2009-06-28 01:00:01] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2009-06-20 11:39:09] paj...@php.net

Can't reproduce it with RC4, please try again with 5.3.0RC4.



[2009-03-02 20:09:55] paj...@php.net

Also see #42832



[2009-03-02 20:01:18] paj...@php.net

I can now reproduce it on XP, but not on 2008/Vista/win7.

I have to investigate deeper :P



[2009-02-03 17:36:35] dani...@php.net

Changing version from 5.2.5 to 5.3.0beta1 to facilitate this getting
fixed before the next release.



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

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



#45552 [Com]: Full circle drawn instead of arc with very small angle

2010-02-12 Thread otoban_faruk at hotmail dot com
 ID:   45552
 Comment by:   otoban_faruk at hotmail dot com
 Reported By:  k...@php.net
 Status:   Assigned
 Bug Type: GD related
 Operating System: Linux 2.6.25-gentoo-r6
 PHP Version:  *
 Assigned To:  pajoye
 New Comment:

Hello. A little government and a little luck are necessary in life, but
only a fool trusts either of them. Help me! I find sites on the topic:
Voice telemarketing. I found only this - http://www.accg.us/Members/Telemarketing/work-at-home-telemarketing-jobs";>work
at home telemarketing jobs. The free disciplinary property changes
and induces political taking surveys that it addresses during the making
risk and demands otherwise to the need of an constant example,
telemarketing. Telemarketing, sharing in 2006, most current spam friends
will get to deploy their programs the ground to confirm their agreement
teamwork telemarketers in the large direct do-not-call 411 telemarketer
elected telemarketing for convenience individuals. With love :o, Elmo
from Tonga.


Previous Comments:


[2008-11-25 19:53:31] paj...@php.net

It is more like a feature request.



[2008-11-25 19:52:19] j...@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





[2008-08-26 16:26:14] michal dot dziemianko at gmail dot com

Hi,
For me it does not seem to be a bug. In the documentation the following
declaration is given:

bool imagefilledarc  ( resource $image  , int $cx  , int $cy  , int
$width  , int $height  , int $start  , int $end  , int $color  , int
$style  )

Your 30.1 is truncated to 30 (conversion to int), then the function is
called with parameters $start=30 and $end =30. 

Please note that start and end values are *angles* at which the arc
starts/ends with respect to 0 degrees. As both start and end are 30 then
it is full circle (drawing starts at 30degrees and goes clockwise all
the way round until 30degrees is hit again). That is behaving as
expected I think. 

Cheers,
Michal



[2008-07-18 09:27:07] k...@php.net

Description:

Instead of a very small arc slice, a full circle is drawn when calling
imagefilledarc with very small angles.

Reproduce code:
---


Expected result:

An image with a very small arc slice.

Actual result:
--
A full circle, like: http://k023.de/imagefilledarc_test.png





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



#39234 [Com]: Retrieve short names to files.

2010-02-12 Thread mvigo at incakola dot com dot pe
 ID:   39234
 Comment by:   mvigo at incakola dot com dot pe
 Reported By:  RQuadling at GMail dot com
 Status:   Open
 Bug Type: Feature/Change Request
 Operating System: Windows XP SP2
 PHP Version:  5CVS-2006-10-23 (snap)
 New Comment:

Good afternoon. The secret of greatness is simple: do better work than
any other man in your field - and keep on doing it. Help me! Can not
find sites on the: Bet on sports income tax. I found only this - http://abcs.tamu.edu/Members/BetOnSports/bet-gambling-sports";>bet
gambling sports. Cortina was ended to have involved states on
chicago's west side and in its complicated seconds that were faced to
face things on online and selection game, connection and system games,
bet on sports. Bet on sports, high help jerrod johnson garnered the
23-yard in the second year, providing two betting odds on three tons,
with a new information by making standard keondra smith. ;-) Thanks in
advance. Muna from Zaire.


Previous Comments:


[2006-10-23 12:39:29] RQuadling at GMail dot com

http://msdn.microsoft.com/library/en-us/fileio/fs/getfullpathname.asp
and
http://msdn.microsoft.com/library/en-us/fileio/fs/getshortpathname.asp

(Maybe these will fit?)



[2006-10-23 12:37:56] RQuadling at GMail dot com

Description:

Hello.

(I was required to pick a version, but that is not really relevant).

This issue extends from a bug/feature of the Windows command shell
executable (cmd.exe) which only allows a single set of double quotes to
be used when being used with the /C option.

e.g.



You get an error which is the same at the command prompt.

These work (the parameter is useless).

C:\windows\system32\calc.exe 123
"C:\windows\system32\calc.exe" 123
C:\windows\system32\calc.exe "123"
"C:\windows\system32\calc.exe" "123"
cmd /c C:\windows\system32\calc.exe 123
cmd /c "C:\windows\system32\calc.exe" 123
cmd /c C:\windows\system32\calc.exe "123"

But this doesn't work at the command line.

cmd /c "C:\windows\system32\calc.exe" "123"

You get the error ...

'C:\windows\system32\calc.exe" "123' is not recognized as an internal
or external command, operable program or batch file.


So, whilst this isn't a PHP bug, PHP could certainly help get around
the problem.


My proposal is to either extend the PHP function realpath() to allow
for a boolean parameter to indicate the short name is to be returned.

e.g.

string realpath ( string path [, boolean return_short_name] )

or to introduce 2 new functions

string shortname ( string longname )
string longname ( string shortname )


In addition, extending the SPL to have a getShortName() method.



To get the shortname within MS VC++, there is a function called
GetShortPathName(). There is also GetLongPathName().

References to these functions can be found at
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/fs/getshortpathname.asp

and
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/fileio/fs/getlongpathname.asp

DWORD GetShortPathName(
  LPCTSTR lpszLongPath,
  LPTSTR lpszShortPath,
  DWORD cchBuffer
);

DWORD GetLongPathName(
  LPCTSTR lpszShortPath,
  LPTSTR lpszLongPath,
  DWORD cchBuffer
);


With the shortname() function, a filename like ...

C:\Program Files\Microsoft SQL Server\80\Tools\Binn\osql.exe

would become ...

C:\PROGRA~1\MI6841~1\80\TOOLS\BINN\OSQL.EXE

The name supplied is system dependent. I have a LOT of directories in
"C:\Program Files" starting with Microsoft.

27/10/2004  15:01  MI3AA1~1 Microsoft ActiveSync
16/03/2006  11:13  MIAF83~1 Microsoft AntiSpyware
05/01/2005  10:02  MIDA86~1 Microsoft Baseline
Security Analyzer
23/02/2005  16:17  MIAF01~1 Microsoft Firewall
Client
27/10/2004  12:13  MICROS~1 microsoft frontpage
06/04/2006  09:22  MICROS~3 Microsoft
IntelliPoint
06/04/2006  09:26  MICROS~2 Microsoft IntelliType
Pro
06/04/2006  10:13  MICROS~4 Microsoft Office
29/10/2004  14:36  MI6841~1 Microsoft SQL Server
16/11/2004  16:31  MIAF9D~1 Microsoft Visual
Studio
28/10/2004  08:44  MIF2B0~1 Microsoft Works
23/02/2005  12:02  MICROS~1.NET Microsoft.NET


In terms of impact, making 2 new functions which are Windows only would
probably be easier.








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



#50392 [Opn->Asn]: date_create_from_format enforces 6 digits for 'u' format character

2010-02-12 Thread jani
 ID:   50392
 Updated by:   j...@php.net
 Reported By:  grodny at oneclick dot sk
-Status:   Open
+Status:   Assigned
 Bug Type: Date/time related
 Operating System: *
 PHP Version:  5.3.1
 Assigned To:  derick


Previous Comments:


[2010-02-11 11:11:49] s...@php.net

Automatic comment from SVN on behalf of pajoye
Revision: http://svn.php.net/viewvc/?view=revision&revision=294880
Log: - merge fix for: #45866,#50930, revert fix for #50392, Fixed a bug
with the 'r' formatting function, added or fixed tests for #45866 and
#46268



[2010-02-10 16:23:33] s...@php.net

Automatic comment from SVN on behalf of derick
Revision: http://svn.php.net/viewvc/?view=revision&revision=294854
Log: - Added a test case for bug #45866
- Fixed tests: oo_002, bug46268
- Fixed bug #50930 (Wrong date by php_date.c patch with ancient
gcc/glibc
  versions).
- Make sure faulty strings passed to DateTime::modify() notify the
user.
- Revert fix for bug #50392 as it was fixed wrongly without a proper
test case.
- Fixed a bug with the 'r' formatting function as the default buffer
size that
  was allocated only fit 4 digit years.



[2010-02-10 14:32:05] der...@php.net

Reopening as this bug was fixed incorrectly. It would treat "0010" as
"10" which is not what it is meant to do. The test case didn't
properly test the values either.



[2009-12-15 12:40:47] il...@php.net

This bug has been fixed in SVN.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.





[2009-12-15 12:34:17] s...@php.net

Automatic comment from SVN on behalf of iliaa
Revision: http://svn.php.net/viewvc/?view=revision&revision=292162
Log: Fixed bu #50392(date_create_from_format() enforces 6 digits for
'u' format character)



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

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



#51029 [Opn->Fbk]: PHP does not display any error message on operations on non-existant database

2010-02-12 Thread jani
 ID:   51029
 Updated by:   j...@php.net
 Reported By:  ahmetsinan at gmail dot com
-Status:   Open
+Status:   Feedback
 Bug Type: MySQL related
 Operating System: Linux
 PHP Version:  5.2SVN-2010-02-12 (SVN)
 New Comment:

Exactly what PHP version are you using? 


Previous Comments:


[2010-02-12 19:53:34] ahmetsinan at gmail dot com

Description:

PHP does not displays any error messages, while inserting to a
non-existant table in non-existant database and creating a table in
non-existant database. Displaying the errors is on.

Reproduce code:
---
$con = mysql_connect("localhost","root","");
if (!$con)
  {
  die('Could not connect: ' . mysql_error());
  }

mysql_select_db("sthnonexistant", $con);
$sql = "CREATE TABLE IF NOT EXISTS `registration` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` varchar(255) NOT NULL,
  `email` varchar(255) NOT NULL,
  UNIQUE KEY `id` (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=0 ;";

mysql_query($sql,$con);

Expected result:

An error message, containing that database does not exist.

Actual result:
--
Success message.





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



#51031 [Opn->Asn]: strtolower.phpt fails

2010-02-12 Thread johannes
 ID:   51031
 Updated by:   johan...@php.net
 Reported By:  geissert at debian dot org
-Status:   Open
+Status:   Assigned
 Bug Type: Strings related
 Operating System: Debian GNU/Linux ia64
 PHP Version:  5.3SVN-2010-02-12 (snap)
-Assigned To:  
+Assigned To:  geissert
 New Comment:

There's no magic to close, just to add comments. Close has to be done
by hand. and your account should work.


Previous Comments:


[2010-02-12 21:47:41] ras...@php.net

Yes, it accepts many formats.  bug #n will work.
Also, if the fix applies to multiple active branches, please commit to

all branches in a single commit.  The active branches are 
branches/PHP_5_2, branches/PHP_5_3 and trunk



[2010-02-12 21:38:26] geissert at debian dot org

Ok, I just created it. One question: what exactly is the magic to close
the bugs from the commit messages? just "\(bug #\d+\)"?



[2010-02-12 21:17:34] ras...@php.net

Could I encourage you to get an svn account and commit some of these 
trivial fixes yourself?  See http://www.php.net/svn.php and click on 
the "get your own account" link on the left there.



[2010-02-12 21:08:34] geissert at debian dot org

Right, got it:

--SKIPIF--
...
  if (!setlocale(LC_ALL, 'en_US.UTF-8', 'en')) {
...

while the test itself does:

  setlocale(LC_ALL, 'en-US.UTF-8');

it should use an underscore instead.



[2010-02-12 21:01:58] ras...@php.net

There is no magic here.  All we are doing is calling the low-level 
tolower() function.  I bet you can recreate the same thing with this:

#include 
#include 

void main(void) {
  int ch;
 
  for(ch=0; ch<256; ch++) {
printf("%x: %x\n",ch,tolower(ch));
  } 
}




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

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



#51031 [Opn]: strtolower.phpt fails

2010-02-12 Thread rasmus
 ID:   51031
 Updated by:   ras...@php.net
 Reported By:  geissert at debian dot org
 Status:   Open
 Bug Type: Strings related
 Operating System: Debian GNU/Linux ia64
 PHP Version:  5.3SVN-2010-02-12 (snap)
 New Comment:

Yes, it accepts many formats.  bug #n will work.
Also, if the fix applies to multiple active branches, please commit to

all branches in a single commit.  The active branches are 
branches/PHP_5_2, branches/PHP_5_3 and trunk


Previous Comments:


[2010-02-12 21:38:26] geissert at debian dot org

Ok, I just created it. One question: what exactly is the magic to close
the bugs from the commit messages? just "\(bug #\d+\)"?



[2010-02-12 21:17:34] ras...@php.net

Could I encourage you to get an svn account and commit some of these 
trivial fixes yourself?  See http://www.php.net/svn.php and click on 
the "get your own account" link on the left there.



[2010-02-12 21:08:34] geissert at debian dot org

Right, got it:

--SKIPIF--
...
  if (!setlocale(LC_ALL, 'en_US.UTF-8', 'en')) {
...

while the test itself does:

  setlocale(LC_ALL, 'en-US.UTF-8');

it should use an underscore instead.



[2010-02-12 21:01:58] ras...@php.net

There is no magic here.  All we are doing is calling the low-level 
tolower() function.  I bet you can recreate the same thing with this:

#include 
#include 

void main(void) {
  int ch;
 
  for(ch=0; ch<256; ch++) {
printf("%x: %x\n",ch,tolower(ch));
  } 
}




[2010-02-12 20:48:30] geissert at debian dot org

the test sets LC_ALL to en-US.UTF-8, but playing a bit more with it if
I set LANG=C (or to en_US.UTF-8) before calling php it works. If, on the
other hand, I set LANG to en_US it fails (this is the case under which I
found the bug).

Somehow LANG is being prioritised over LC_ALL.



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

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



#51026 [Opn]: ssl not working

2010-02-12 Thread fuxa_kos at unihost dot cz
 ID:   51026
 User updated by:  fuxa_kos at unihost dot cz
 Reported By:  fuxa_kos at unihost dot cz
 Status:   Open
 Bug Type: MySQLi related
 Operating System: Linux
 PHP Version:  5.3.1
 New Comment:

In my case, tested at latest CentOS 5 and 4. All 64-bit boxes, PHP 
compiled myself from sources. With Mysql 5.0.89, 5.0.90, 5.1.42.


Previous Comments:


[2010-02-12 21:39:48] fuxa_kos at unihost dot cz

same problem

phpinfo()
PHP Version => 5.3.3-dev

# ssl_set
mysqli::ssl_set(): invalid object or resource mysqli
var_dump returns NULL

# real_connect, without MYSQLI_CLIENT_SSL
error: mysqli::real_connect(): (28000/1045): Access denied for 
user '...' (using password: YES)
errno: 1045

# real_connect, with MYSQLI_CLIENT_SSL
error: mysqli::real_connect(): (HY000/2003): Can't connect to MySQL 
server on '...' (113)
errno: 2003



[2010-02-12 16:14:01] j...@php.net

Please try using this snapshot:

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

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





[2010-02-12 13:02:55] fuxa_kos at unihost dot cz

Description:

ssl connection not working, same code with 5.2.12 working well.
With reference to bug 49234, I have support [33] => ssl_set.

mysql client working well too.
mysql ... --ssl-ca=cert/mysql-cacert.pem
--ssl-cert=cert/client-cert.pem --ssl-key=cert/client-key.pem
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 116395
Server version: 5.0.90-community-log MySQL Community Edition (GPL)
mysql> SHOW STATUS LIKE 'Ssl_cipher';
+---++
| Variable_name | Value  |
+---++
| Ssl_cipher| DHE-RSA-AES256-SHA |
+---++
1 row in set (0.00 sec)

from phpinfo
mysqli

MysqlI Support => enabled
Client API library version => 5.1.42
Active Persistent Links => 0
Inactive Persistent Links => 0
Active Links => 0
Client API header version => 5.1.42
MYSQLI_SOCKET => /var/lib/mysql/mysql.sock

Directive => Local Value => Master Value
mysqli.allow_local_infile => Off => Off
mysqli.allow_persistent => On => On
mysqli.default_host => no value => no value
mysqli.default_port => 3306 => 3306
mysqli.default_pw => no value => no value
mysqli.default_socket => no value => no value
mysqli.default_user => no value => no value
mysqli.max_links => Unlimited => Unlimited
mysqli.max_persistent => Unlimited => Unlimited
mysqli.reconnect => Off => Off

Client is Mysql 5.1 and server is Mysql 5.0. But same for 5.0 Mysql 
client. In case PHP 5.2 Mysql client is 5.0.

Reproduce code:
---
ssl_set('./cert/client-key.pem', './cert/client-cert.pem',
'./cert/mysql-cacert.pem', null, null);
$mysqli->real_connect('removed', '', '', '');
if ($r = $mysqli->query("SHOW STATUS LIKE 'Ssl_cipher'")) {
var_dump($r->fetch_row());
}
echo $mysqli->error."\n";
echo $mysqli->errno."\n";

Expected result:

something like this for Ssl_cipher
array(2) {
  [0]=>
  string(10) "Ssl_cipher"
  [1]=>
  string(18) "DHE-RSA-AES256-SHA"
}

and no errors.

Actual result:
--
Warning: mysqli::ssl_set(): invalid object or resource mysqli

with MYSQLI_CLIENT_SSL
Can't connect to MySQL server on 'removed' (113)
errno = 2003
 
without MYSQLI_CLIENT_SSL
Warning: mysqli::real_connect(): (28000/1045): Access denied for 
user 'removed' (using password: YES)
errno = 1045

ssl_set() in this case returns NULL, not true as doc says.





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



#51026 [Fbk->Opn]: ssl not working

2010-02-12 Thread fuxa_kos at unihost dot cz
 ID:   51026
 User updated by:  fuxa_kos at unihost dot cz
 Reported By:  fuxa_kos at unihost dot cz
-Status:   Feedback
+Status:   Open
 Bug Type: MySQLi related
 Operating System: Linux
 PHP Version:  5.3.1
 New Comment:

same problem

phpinfo()
PHP Version => 5.3.3-dev

# ssl_set
mysqli::ssl_set(): invalid object or resource mysqli
var_dump returns NULL

# real_connect, without MYSQLI_CLIENT_SSL
error: mysqli::real_connect(): (28000/1045): Access denied for 
user '...' (using password: YES)
errno: 1045

# real_connect, with MYSQLI_CLIENT_SSL
error: mysqli::real_connect(): (HY000/2003): Can't connect to MySQL 
server on '...' (113)
errno: 2003


Previous Comments:


[2010-02-12 16:14:01] j...@php.net

Please try using this snapshot:

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

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





[2010-02-12 13:02:55] fuxa_kos at unihost dot cz

Description:

ssl connection not working, same code with 5.2.12 working well.
With reference to bug 49234, I have support [33] => ssl_set.

mysql client working well too.
mysql ... --ssl-ca=cert/mysql-cacert.pem
--ssl-cert=cert/client-cert.pem --ssl-key=cert/client-key.pem
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 116395
Server version: 5.0.90-community-log MySQL Community Edition (GPL)
mysql> SHOW STATUS LIKE 'Ssl_cipher';
+---++
| Variable_name | Value  |
+---++
| Ssl_cipher| DHE-RSA-AES256-SHA |
+---++
1 row in set (0.00 sec)

from phpinfo
mysqli

MysqlI Support => enabled
Client API library version => 5.1.42
Active Persistent Links => 0
Inactive Persistent Links => 0
Active Links => 0
Client API header version => 5.1.42
MYSQLI_SOCKET => /var/lib/mysql/mysql.sock

Directive => Local Value => Master Value
mysqli.allow_local_infile => Off => Off
mysqli.allow_persistent => On => On
mysqli.default_host => no value => no value
mysqli.default_port => 3306 => 3306
mysqli.default_pw => no value => no value
mysqli.default_socket => no value => no value
mysqli.default_user => no value => no value
mysqli.max_links => Unlimited => Unlimited
mysqli.max_persistent => Unlimited => Unlimited
mysqli.reconnect => Off => Off

Client is Mysql 5.1 and server is Mysql 5.0. But same for 5.0 Mysql 
client. In case PHP 5.2 Mysql client is 5.0.

Reproduce code:
---
ssl_set('./cert/client-key.pem', './cert/client-cert.pem',
'./cert/mysql-cacert.pem', null, null);
$mysqli->real_connect('removed', '', '', '');
if ($r = $mysqli->query("SHOW STATUS LIKE 'Ssl_cipher'")) {
var_dump($r->fetch_row());
}
echo $mysqli->error."\n";
echo $mysqli->errno."\n";

Expected result:

something like this for Ssl_cipher
array(2) {
  [0]=>
  string(10) "Ssl_cipher"
  [1]=>
  string(18) "DHE-RSA-AES256-SHA"
}

and no errors.

Actual result:
--
Warning: mysqli::ssl_set(): invalid object or resource mysqli

with MYSQLI_CLIENT_SSL
Can't connect to MySQL server on 'removed' (113)
errno = 2003
 
without MYSQLI_CLIENT_SSL
Warning: mysqli::real_connect(): (28000/1045): Access denied for 
user 'removed' (using password: YES)
errno = 1045

ssl_set() in this case returns NULL, not true as doc says.





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



#51031 [Com]: strtolower.phpt fails

2010-02-12 Thread geissert at debian dot org
 ID:   51031
 Comment by:   geissert at debian dot org
 Reported By:  geissert at debian dot org
 Status:   Open
 Bug Type: Strings related
 Operating System: Debian GNU/Linux ia64
 PHP Version:  5.3SVN-2010-02-12 (snap)
 New Comment:

Ok, I just created it. One question: what exactly is the magic to close
the bugs from the commit messages? just "\(bug #\d+\)"?


Previous Comments:


[2010-02-12 21:17:34] ras...@php.net

Could I encourage you to get an svn account and commit some of these 
trivial fixes yourself?  See http://www.php.net/svn.php and click on 
the "get your own account" link on the left there.



[2010-02-12 21:08:34] geissert at debian dot org

Right, got it:

--SKIPIF--
...
  if (!setlocale(LC_ALL, 'en_US.UTF-8', 'en')) {
...

while the test itself does:

  setlocale(LC_ALL, 'en-US.UTF-8');

it should use an underscore instead.



[2010-02-12 21:01:58] ras...@php.net

There is no magic here.  All we are doing is calling the low-level 
tolower() function.  I bet you can recreate the same thing with this:

#include 
#include 

void main(void) {
  int ch;
 
  for(ch=0; ch<256; ch++) {
printf("%x: %x\n",ch,tolower(ch));
  } 
}




[2010-02-12 20:48:30] geissert at debian dot org

the test sets LC_ALL to en-US.UTF-8, but playing a bit more with it if
I set LANG=C (or to en_US.UTF-8) before calling php it works. If, on the
other hand, I set LANG to en_US it fails (this is the case under which I
found the bug).

Somehow LANG is being prioritised over LC_ALL.



[2010-02-12 20:31:03] ras...@php.net

LOCALE?

Ok for me on 64-bit Debian with latest 5.3.3-svn



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

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



#23022 [Com]: Supported dereferencing array indeces on arbitrary expressions

2010-02-12 Thread zeb at zebhodge dot com
 ID:   23022
 Comment by:   zeb at zebhodge dot com
 Reported By:  mfisc...@php.net
 Status:   Open
 Bug Type: Feature/Change Request
 Operating System: Any
 PHP Version:  5CVS-2003-04-02 (dev)
 New Comment:

I'm baffled that this doesn't work in PHP like it does in so many other

languages.


Previous Comments:


[2009-12-31 06:26:48] billyellison99 at gmail dot com

I fully support this feature. It'd make my life a whole lot easier, and

make my code much neater and smaller.



[2009-11-10 03:47:40] kexianbin at diyism dot com

For objects, you could hack like this:
class user
  {public $username='jack';
   public function __get($prop_name)
  {return $this->$prop_name();
  }
   private function degree()
   {return array('doctor', 'master');
   }
  }
$aUser=new user();
echo $aUser->degree[1];



[2009-11-05 05:43:34] glennwidener at gmail dot com

I found this lack of symmetry in array references really lame too.  If
an expression delivers an array, then you should be able to reference an
element of that array.  The only question is operator precedence and
grouping: recommend following the C rules - primary expressions group
left to right, parenthesis disambiguate.



[2009-02-26 08:44:45] kexianbin at diyism dot com

When could we realize this in php?

create_function('$v', <<<'fun_code'
echo $v;
fun_code
)('hello');



[2009-02-26 08:20:58] kexianbin at diyism dot com

When could we realize this in php?

create_function('$v', <<<'fun_code'
echo $v;
fun_code
')('hello');



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

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



#51032 [NEW]: bug42718.phpt fails

2010-02-12 Thread geissert at debian dot org
From: geissert at debian dot org
Operating system: Debian GNU/Linux ia64
PHP version:  5.3SVN-2010-02-12 (snap)
PHP Bug Type: Filter related
Bug description:  bug42718.phpt fails

Description:

The test fails now, while it does pass with 5.3.1

Expected result:

unsafe_raw
4
bool(true)
1


Actual result:
--
unsafe_raw
4
bool(true)
1\000


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



#51031 [Opn]: strtolower.phpt fails

2010-02-12 Thread rasmus
 ID:   51031
 Updated by:   ras...@php.net
 Reported By:  geissert at debian dot org
 Status:   Open
 Bug Type: Strings related
 Operating System: Debian GNU/Linux ia64
 PHP Version:  5.3SVN-2010-02-12 (snap)
 New Comment:

Could I encourage you to get an svn account and commit some of these 
trivial fixes yourself?  See http://www.php.net/svn.php and click on 
the "get your own account" link on the left there.


Previous Comments:


[2010-02-12 21:08:34] geissert at debian dot org

Right, got it:

--SKIPIF--
...
  if (!setlocale(LC_ALL, 'en_US.UTF-8', 'en')) {
...

while the test itself does:

  setlocale(LC_ALL, 'en-US.UTF-8');

it should use an underscore instead.



[2010-02-12 21:01:58] ras...@php.net

There is no magic here.  All we are doing is calling the low-level 
tolower() function.  I bet you can recreate the same thing with this:

#include 
#include 

void main(void) {
  int ch;
 
  for(ch=0; ch<256; ch++) {
printf("%x: %x\n",ch,tolower(ch));
  } 
}




[2010-02-12 20:48:30] geissert at debian dot org

the test sets LC_ALL to en-US.UTF-8, but playing a bit more with it if
I set LANG=C (or to en_US.UTF-8) before calling php it works. If, on the
other hand, I set LANG to en_US it fails (this is the case under which I
found the bug).

Somehow LANG is being prioritised over LC_ALL.



[2010-02-12 20:31:03] ras...@php.net

LOCALE?

Ok for me on 64-bit Debian with latest 5.3.3-svn



[2010-02-12 20:28:33] geissert at debian dot org

Description:

The test fails with the latest snapshot, 5.3.1 worked fine

Reproduce code:
---
echo "*** Testing strtolower() with all 256 chars ***\n";
for ($i=0; $i<=255; $i++){
  $char = chr($i);
  print(bin2hex($char))." => ".(bin2hex(strtolower("$char")))."\n";
}

Expected result:

*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf
c0 => c0
c1 => c1
c2 => c2
c3 => c3
c4 => c4
c5 => c5
c6 => c6
c7 => c7
c8 => c8
c9 => c9
ca => ca
cb => cb
cc => cc
cd => cd
ce => ce
cf => cf
d0 => d0
d1 => d1
...


Actual result:
--
*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf  // error:
c0 => e0
c1 => e1
c2 => e2
c3 => e3
c4 => e4
c5 => e5
c6 => e6
c7 => e7
c8 => e8
c9 => e9
ca => ea
cb => eb
cc => ec
cd => ed
ce => ee
cf => ef
d0 => f0
d1 => f1
d2 => f2
d3 => f3
d4 => f4
d5 => f5
d6 => f6
d7 => d7
d8 => f8
d9 => f9
da => fa
db => fb
dc => fc
dd => fd
de => fe
df => df
e0 => e0 //the rest is fine
...





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



#7847 [Com]: OCI8 support with Oracle 8.1.5 doesn't work

2010-02-12 Thread gvega at peru dot com
 ID:   7847
 Comment by:   gvega at peru dot com
 Reported By:  msquillace at sogei dot it
 Status:   No Feedback
 Bug Type: OCI8 related
 Operating System: AIX 4.2
 PHP Version:  4.0.3pl1
 New Comment:

Hey. The louder he talked of his honor, the faster we counted our
spoons. Help me! Help to find sites on the: Low cost brochure printing.
I found only this - http://www.honbu.fi/Members/BrochurePrinting/brochure-printing-templates";>brochure
printing templates. Brochure printing, until 1982, halland nyheter
had troops on its online research. Brochure printing, raw dpi want that
because of his good export, neilson marched brochure at the host of
brochure and destroyed to the united states at the invincibility of
eighteen. Thank you very much :rolleyes:. Reeve from United.


Previous Comments:


[2002-02-02 06:41:09] san...@php.net

No feedback was provided for this bug, so it is being suspended.
If you are able to provide the information that was requested,
please do so and change the status of the bug back to "Open".



[2002-01-11 16:49:56] lob...@php.net

Can you reproduce this with PHP 4.1.1?



[2001-01-08 09:13:58] msquillace at sogei dot it

Downloaded php4-200101080345 this morning and recompiled libphp4.so.
The problems remain. I had to find out an AIX 4.3.3 server in order to
keep the project in schedule; I successfully built a STATIC php module
there, including a working OCI8 extension. I couldn't build a working
AIX 4.3 DSO even though I followed the advice in bug #4630.



[2001-01-07 19:42:19] sni...@php.net

Does this happen with latest snapshot from http://snaps.php.net/ ??

--Jani



[2000-12-07 05:46:25] msquillace at sogei dot it

I have been testing several other extensions and standard PHP functions
on my AIX 4.2 server, and discovered the following:

1) can't successfully build PHP with socket support
2) fsockopen fails as described for OCI8
3) curl fails as described for OCI8

Since OCIServerAttach must certainly work with sockets at some point,
may this point to some kind of incompatibility between PHP and AIX 4.2
socket code?




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

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



#51031 [Com]: strtolower.phpt fails

2010-02-12 Thread geissert at debian dot org
 ID:   51031
 Comment by:   geissert at debian dot org
 Reported By:  geissert at debian dot org
 Status:   Open
 Bug Type: Strings related
 Operating System: Debian GNU/Linux ia64
 PHP Version:  5.3SVN-2010-02-12 (snap)
 New Comment:

Right, got it:

--SKIPIF--
...
  if (!setlocale(LC_ALL, 'en_US.UTF-8', 'en')) {
...

while the test itself does:

  setlocale(LC_ALL, 'en-US.UTF-8');

it should use an underscore instead.


Previous Comments:


[2010-02-12 21:01:58] ras...@php.net

There is no magic here.  All we are doing is calling the low-level 
tolower() function.  I bet you can recreate the same thing with this:

#include 
#include 

void main(void) {
  int ch;
 
  for(ch=0; ch<256; ch++) {
printf("%x: %x\n",ch,tolower(ch));
  } 
}




[2010-02-12 20:48:30] geissert at debian dot org

the test sets LC_ALL to en-US.UTF-8, but playing a bit more with it if
I set LANG=C (or to en_US.UTF-8) before calling php it works. If, on the
other hand, I set LANG to en_US it fails (this is the case under which I
found the bug).

Somehow LANG is being prioritised over LC_ALL.



[2010-02-12 20:31:03] ras...@php.net

LOCALE?

Ok for me on 64-bit Debian with latest 5.3.3-svn



[2010-02-12 20:28:33] geissert at debian dot org

Description:

The test fails with the latest snapshot, 5.3.1 worked fine

Reproduce code:
---
echo "*** Testing strtolower() with all 256 chars ***\n";
for ($i=0; $i<=255; $i++){
  $char = chr($i);
  print(bin2hex($char))." => ".(bin2hex(strtolower("$char")))."\n";
}

Expected result:

*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf
c0 => c0
c1 => c1
c2 => c2
c3 => c3
c4 => c4
c5 => c5
c6 => c6
c7 => c7
c8 => c8
c9 => c9
ca => ca
cb => cb
cc => cc
cd => cd
ce => ce
cf => cf
d0 => d0
d1 => d1
...


Actual result:
--
*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf  // error:
c0 => e0
c1 => e1
c2 => e2
c3 => e3
c4 => e4
c5 => e5
c6 => e6
c7 => e7
c8 => e8
c9 => e9
ca => ea
cb => eb
cc => ec
cd => ed
ce => ee
cf => ef
d0 => f0
d1 => f1
d2 => f2
d3 => f3
d4 => f4
d5 => f5
d6 => f6
d7 => d7
d8 => f8
d9 => f9
da => fa
db => fb
dc => fc
dd => fd
de => fe
df => df
e0 => e0 //the rest is fine
...





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



#51031 [Opn]: strtolower.phpt fails

2010-02-12 Thread rasmus
 ID:   51031
 Updated by:   ras...@php.net
 Reported By:  geissert at debian dot org
 Status:   Open
 Bug Type: Strings related
 Operating System: Debian GNU/Linux ia64
 PHP Version:  5.3SVN-2010-02-12 (snap)
 New Comment:

There is no magic here.  All we are doing is calling the low-level 
tolower() function.  I bet you can recreate the same thing with this:

#include 
#include 

void main(void) {
  int ch;
 
  for(ch=0; ch<256; ch++) {
printf("%x: %x\n",ch,tolower(ch));
  } 
}



Previous Comments:


[2010-02-12 20:48:30] geissert at debian dot org

the test sets LC_ALL to en-US.UTF-8, but playing a bit more with it if
I set LANG=C (or to en_US.UTF-8) before calling php it works. If, on the
other hand, I set LANG to en_US it fails (this is the case under which I
found the bug).

Somehow LANG is being prioritised over LC_ALL.



[2010-02-12 20:31:03] ras...@php.net

LOCALE?

Ok for me on 64-bit Debian with latest 5.3.3-svn



[2010-02-12 20:28:33] geissert at debian dot org

Description:

The test fails with the latest snapshot, 5.3.1 worked fine

Reproduce code:
---
echo "*** Testing strtolower() with all 256 chars ***\n";
for ($i=0; $i<=255; $i++){
  $char = chr($i);
  print(bin2hex($char))." => ".(bin2hex(strtolower("$char")))."\n";
}

Expected result:

*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf
c0 => c0
c1 => c1
c2 => c2
c3 => c3
c4 => c4
c5 => c5
c6 => c6
c7 => c7
c8 => c8
c9 => c9
ca => ca
cb => cb
cc => cc
cd => cd
ce => ce
cf => cf
d0 => d0
d1 => d1
...


Actual result:
--
*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf  // error:
c0 => e0
c1 => e1
c2 => e2
c3 => e3
c4 => e4
c5 => e5
c6 => e6
c7 => e7
c8 => e8
c9 => e9
ca => ea
cb => eb
cc => ec
cd => ed
ce => ee
cf => ef
d0 => f0
d1 => f1
d2 => f2
d3 => f3
d4 => f4
d5 => f5
d6 => f6
d7 => d7
d8 => f8
d9 => f9
da => fa
db => fb
dc => fc
dd => fd
de => fe
df => df
e0 => e0 //the rest is fine
...





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



#51031 [Com]: strtolower.phpt fails

2010-02-12 Thread geissert at debian dot org
 ID:   51031
 Comment by:   geissert at debian dot org
 Reported By:  geissert at debian dot org
 Status:   Open
 Bug Type: Strings related
 Operating System: Debian GNU/Linux ia64
 PHP Version:  5.3SVN-2010-02-12 (snap)
 New Comment:

the test sets LC_ALL to en-US.UTF-8, but playing a bit more with it if
I set LANG=C (or to en_US.UTF-8) before calling php it works. If, on the
other hand, I set LANG to en_US it fails (this is the case under which I
found the bug).

Somehow LANG is being prioritised over LC_ALL.


Previous Comments:


[2010-02-12 20:31:03] ras...@php.net

LOCALE?

Ok for me on 64-bit Debian with latest 5.3.3-svn



[2010-02-12 20:28:33] geissert at debian dot org

Description:

The test fails with the latest snapshot, 5.3.1 worked fine

Reproduce code:
---
echo "*** Testing strtolower() with all 256 chars ***\n";
for ($i=0; $i<=255; $i++){
  $char = chr($i);
  print(bin2hex($char))." => ".(bin2hex(strtolower("$char")))."\n";
}

Expected result:

*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf
c0 => c0
c1 => c1
c2 => c2
c3 => c3
c4 => c4
c5 => c5
c6 => c6
c7 => c7
c8 => c8
c9 => c9
ca => ca
cb => cb
cc => cc
cd => cd
ce => ce
cf => cf
d0 => d0
d1 => d1
...


Actual result:
--
*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf  // error:
c0 => e0
c1 => e1
c2 => e2
c3 => e3
c4 => e4
c5 => e5
c6 => e6
c7 => e7
c8 => e8
c9 => e9
ca => ea
cb => eb
cc => ec
cd => ed
ce => ee
cf => ef
d0 => f0
d1 => f1
d2 => f2
d3 => f3
d4 => f4
d5 => f5
d6 => f6
d7 => d7
d8 => f8
d9 => f9
da => fa
db => fb
dc => fc
dd => fd
de => fe
df => df
e0 => e0 //the rest is fine
...





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



#27316 [Com]: Automatically add PHP directory to PATH

2010-02-12 Thread info at adora dot it
 ID:   27316
 Comment by:   info at adora dot it
 Reported By:  php at koteroff dot ru
 Status:   Open
 Bug Type: Feature/Change Request
 Operating System: Windows
 PHP Version:  5.0.0b4 (beta4)
 New Comment:

www.adora.it


Previous Comments:


[2004-02-21 10:16:56] php at koteroff dot ru

If you want I can patch PHP myself and send you diff. But I want to be
sure that this diff will be applied in official distribution.



[2004-02-19 04:25:14] php at koteroff dot ru

I test all on Windows 98. If I do not add PHP directory to PATH before
running Apache (in BAT-file, for example), while including php_mysql.dll
it cannot fing libmysql.dll. I used filemon to determine where does it
search for, and see that it is Apache directory and directories in PATH
— nothing else.

It can be understood: by default Windows searches for DLLs in current
directory, in directory, where main exe (apache.exe) resides and in
PATH. No other pathes.

P.S.
Now I'm working on second edition of my book, and here is the chapter
about instlalling PHP as CGI and as module. CGI installation occupies
only one page, but module installation — about 6 pages (including
description of every potencial reefs). I'd like to say also that a lot
of other subsystems (Perl, MySQL, Art. Lebedev's Parser, Apache itself
etc.) greatly works without ANY manipulation with PATH and other
environment. They are autonomous. Nowadays PHP is annoying exclusion.



[2004-02-18 19:27:21] ed...@php.net

Php.ini issues aside, why would you want to add php folder to the path?
It should work without it, at least on newer windows versions. What
version of windows are you using?



[2004-02-18 17:26:30] php at koteroff dot ru

Description:

New PHP distribution directory structure is great. Now php.exe works
immediately after unpacking & modifying php.ini.

But with mod_php thinks are worse. To make him start I have to:
1. Set PHPRC environment variable equal to PHP5 directory path (to
search php.ini in this directory - for example, let it be
z:/usr/local/php5).
2. Manually add z:/usr/local/php5 to PATH to allow PHP search for
libmysql.dll, libeay32.dll etc. while loading extensions.

It is too importunate and makes mod_php usage greatly harder than CGI
version using. That's why I ask you to add the following features:

1. By default search php.ini not only in apache directory (it's silly)
and in windows directory (it's silly twice - nothing personal: nobody
wants to trash windows folder), but at php5apache.dll directory too.
2. Also add directory in which php5apache.dll resides to PATH (possibly
at php5apache startup code).

These changes will unversalize PHP and make mod_php installation not
harder than CGI installation. (I'd like to say thet a lot of people uses
Windows-PHP in debugging purposes. That's why they have 2 or 3 different
version of PHP at the same server.)

To get current module name, we may use GetModuleFileName API call. To
set environment variable PATH GetEnvironmentVariable and
SetEnvironmentVariable may be used.

Please answer what do you thing about all of these?






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



#51031 [Opn]: strtolower.phpt fails

2010-02-12 Thread rasmus
 ID:   51031
 Updated by:   ras...@php.net
 Reported By:  geissert at debian dot org
 Status:   Open
 Bug Type: Strings related
 Operating System: Debian GNU/Linux ia64
 PHP Version:  5.3SVN-2010-02-12 (snap)
 New Comment:

LOCALE?

Ok for me on 64-bit Debian with latest 5.3.3-svn


Previous Comments:


[2010-02-12 20:28:33] geissert at debian dot org

Description:

The test fails with the latest snapshot, 5.3.1 worked fine

Reproduce code:
---
echo "*** Testing strtolower() with all 256 chars ***\n";
for ($i=0; $i<=255; $i++){
  $char = chr($i);
  print(bin2hex($char))." => ".(bin2hex(strtolower("$char")))."\n";
}

Expected result:

*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf
c0 => c0
c1 => c1
c2 => c2
c3 => c3
c4 => c4
c5 => c5
c6 => c6
c7 => c7
c8 => c8
c9 => c9
ca => ca
cb => cb
cc => cc
cd => cd
ce => ce
cf => cf
d0 => d0
d1 => d1
...


Actual result:
--
*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf  // error:
c0 => e0
c1 => e1
c2 => e2
c3 => e3
c4 => e4
c5 => e5
c6 => e6
c7 => e7
c8 => e8
c9 => e9
ca => ea
cb => eb
cc => ec
cd => ed
ce => ee
cf => ef
d0 => f0
d1 => f1
d2 => f2
d3 => f3
d4 => f4
d5 => f5
d6 => f6
d7 => d7
d8 => f8
d9 => f9
da => fa
db => fb
dc => fc
dd => fd
de => fe
df => df
e0 => e0 //the rest is fine
...





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



#51031 [NEW]: strtolower.phpt fails

2010-02-12 Thread geissert at debian dot org
From: geissert at debian dot org
Operating system: Debian GNU/Linux ia64
PHP version:  5.3SVN-2010-02-12 (snap)
PHP Bug Type: Strings related
Bug description:  strtolower.phpt fails

Description:

The test fails with the latest snapshot, 5.3.1 worked fine

Reproduce code:
---
echo "*** Testing strtolower() with all 256 chars ***\n";
for ($i=0; $i<=255; $i++){
  $char = chr($i);
  print(bin2hex($char))." => ".(bin2hex(strtolower("$char")))."\n";
}

Expected result:

*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf
c0 => c0
c1 => c1
c2 => c2
c3 => c3
c4 => c4
c5 => c5
c6 => c6
c7 => c7
c8 => c8
c9 => c9
ca => ca
cb => cb
cc => cc
cd => cd
ce => ce
cf => cf
d0 => d0
d1 => d1
...


Actual result:
--
*** Testing strtolower() with all 256 chars ***
00 => 00
01 => 01
02 => 02
03 => 03
04 => 04
05 => 05
06 => 06
07 => 07
08 => 08
09 => 09
0a => 0a
0b => 0b
0c => 0c
0d => 0d
0e => 0e
0f => 0f
...
bf => bf  // error:
c0 => e0
c1 => e1
c2 => e2
c3 => e3
c4 => e4
c5 => e5
c6 => e6
c7 => e7
c8 => e8
c9 => e9
ca => ea
cb => eb
cc => ec
cd => ed
ce => ee
cf => ef
d0 => f0
d1 => f1
d2 => f2
d3 => f3
d4 => f4
d5 => f5
d6 => f6
d7 => d7
d8 => f8
d9 => f9
da => fa
db => fb
dc => fc
dd => fd
de => fe
df => df
e0 => e0 //the rest is fine
...

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



#51029 [NEW]: PHP does not display any error message on operations on non-existant database

2010-02-12 Thread ahmetsinan at gmail dot com
From: ahmetsinan at gmail dot com
Operating system: Linux
PHP version:  5.2SVN-2010-02-12 (SVN)
PHP Bug Type: MySQL related
Bug description:  PHP does not display any error message on operations on 
non-existant database

Description:

PHP does not displays any error messages, while inserting to a
non-existant table in non-existant database and creating a table in
non-existant database. Displaying the errors is on.

Reproduce code:
---
$con = mysql_connect("localhost","root","");
if (!$con)
  {
  die('Could not connect: ' . mysql_error());
  }

mysql_select_db("sthnonexistant", $con);
$sql = "CREATE TABLE IF NOT EXISTS `registration` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` varchar(255) NOT NULL,
  `email` varchar(255) NOT NULL,
  UNIQUE KEY `id` (`id`)
) ENGINE=MyISAM  DEFAULT CHARSET=latin1 AUTO_INCREMENT=0 ;";

mysql_query($sql,$con);

Expected result:

An error message, containing that database does not exist.

Actual result:
--
Success message.

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



#51000 [Com]: unaligned memory access in ext/hash/hash_tiger.c

2010-02-12 Thread geissert at debian dot org
 ID:   51000
 Comment by:   geissert at debian dot org
 Reported By:  geissert at debian dot org
 Status:   Feedback
 Bug Type: hash related
 Operating System: linux ia64
 PHP Version:  5.3.1
 New Comment:

Re-checking this one, I don't see how that line would lead to an
unaligned memory access, so I probably just copied the wrong line. If
that's so, this is a duplicate of 51003.
Sorry for the noise.


Previous Comments:


[2010-02-12 17:15:46] j...@php.net

Please try using this snapshot:

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

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

Sorry, wrong branch in previous post. :)



[2010-02-10 19:24:03] geissert at debian dot org

Description:

There's an unaligned memory access on PHP_TIGERUpdate():

context->passed += 512;







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



#47418 [Com]: number_format misbehaving with some values

2010-02-12 Thread tdietsche at comcast dot net
 ID:   47418
 Comment by:   tdietsche at comcast dot net
 Reported By:  cu19 at gmx dot de
 Status:   Feedback
 Bug Type: *Math Functions
 Operating System: Win7
 PHP Version:  5.3.1
 New Comment:

Yes, I will do that and email you a link. The information is
confidential so I must first remove people's personal information first
(names etc). Please remove the file when you are done with it.


Previous Comments:


[2010-02-12 14:18:15] paj...@php.net

It could be an encoding issue then (before it gets formatted). Can you
zip the script and the excel file you use and post a link to it here? Or
drop me a mail.



[2010-02-12 14:15:30] tdietsche at comcast dot net

I am not sure what you mean by "isolate the value which causes problems
and pass it directly to number_format". If I just assign 19 to a
variable (either as a string or as a number) and do this, it works fine.
It is only when it comes from a result row value of a number-formatted
excel spreadsheet cell that it shows the problem, for me.

You could try a much simpler spreadsheet but I gave all the details of
the one I am using that shows the problem, in case for some reason the
spreadsheet details are related somehow (probably not though).

I don't have time to install a new version of php right now, maybe
later. I have already spent more time on this than I can afford.

One other note, I see in playing around I changed some variable names
in one function, it should really read:

function FmtAmt($amt) {
  // another workaround for the total
  if ((string)$amt == '18.:') $amt = '19';  
  $cred = '';
  if ($amt < 0) {
$amt  = 0 - $amt;
$cred = 'CR';
  }
  // uncomment this and comment out next line to see bug
  // $ret = number_format($amt, 2) . $cred;  
  $ret = stupid_php($amt) . $cred;
  return $ret;
}



[2010-02-12 14:07:58] paj...@php.net

Can you try to isolate the value which causes problems and pass it
directly to number_format? That will be easier to debug and fix.

Can you aslo try using 5.3.2RC2 (VC9 builds if possible, via CLI or
using apachelounge.com's apache).



[2010-02-12 13:32:28] tdietsche at comcast dot net

In case it might help, here is my php config (on WinXP SP3):


  PHP Version 5.3.1


System  Windows NT DIY2004 5.1 build 2600 (Windows XP Professional
Service Pack 3) i586
Build Date  Nov 19 2009 10:16:45
CompilerMSVC6 (Visual C++ 6.0)
Architecturex86
Configure Command   cscript /nologo configure.js
"--enable-snapshot-build" "--disable-isapi" "--enable-debug-pack"
"--disable-isapi"
"--with-pdo-oci=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8-11g=D:\php-sdk\oracle\instantclient11\sdk,shared"
"--enable-object-out-dir=../obj/"
Server API  Apache 2.0 Handler
Virtual Directory Support   enabled
Configuration File (php.ini) Path   C:\WINDOWS
Loaded Configuration File   C:\PHP\php.ini
Scan this dir for additional .ini files (none)
Additional .ini files parsed(none)
PHP API 20090626
PHP Extension   20090626
Zend Extension  220090626
Zend Extension BuildAPI220090626,TS,VC6
PHP Extension Build API20090626,TS,VC6
Debug Build no
Thread Safety   enabled
Zend Memory Manager enabled
Zend Multibyte Support  disabled
IPv6 Supportenabled
Registered PHP Streams  php, file, glob, data, http, ftp, zip,
compress.zlib, compress.bzip2, https, ftps, phar
Registered Stream Socket Transports tcp, udp, ssl, sslv3, sslv2, tls
Registered Stream Filters   convert.iconv.*, string.rot13,
string.toupper, string.tolower, string.strip_tags, convert.*,
consumed,
dechunk, zlib.*, bzip2.*



[2010-02-12 13:19:29] tdietsche at comcast dot net

/* 
set up an Excel 97-2003 spreadsheet with a worksheet 'Nov'
and the row headers below on row 3
then add a row 14 with "John Smith" in Tenant, "11" in Lot, and "19" in
Late Fee.
Late fee should be number format with 2 decimals and comma thousands
separator format.
Create an odbc system DSN called "rent_2009" linked to it.
Then run this script against it, I have stripped it down but I think it
will show the problem.
note this will NOT show the problem if you just supply variable values
directly, it has to come
from excel and has something to do with the (string) casting of values
that excel thinks are numbers.
somehow the float and string are getting goofed up. Even when I fixed
the value, the total it was
being added to still had the problem until I hardwired a second test on
"18.:0" to fix that. Jeez.

(row headers):
Tenant
Lot
Prev Bal
Rent
LP Gas
Taxes
Garbage
El

#50998 [Com]: unaligned memory access in hash_tiger.c

2010-02-12 Thread geissert at debian dot org
 ID:   50998
 Comment by:   geissert at debian dot org
 Reported By:  geissert at debian dot org
 Status:   Feedback
 Bug Type: hash related
 Operating System: linux ia64
 PHP Version:  5.3.1
 New Comment:

Still present...


Previous Comments:


[2010-02-12 17:16:46] j...@php.net

Please try using this snapshot:

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

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





[2010-02-10 21:06:30] geissert at debian dot org

Failed test: ext/hash/tests/mhash_001.phpt

Output:
MHASH_MD5
ok

MHASH_SHA1
ok

MHASH_HAVAL256
ok

MHASH_HAVAL192
ok

MHASH_HAVAL224
ok

MHASH_HAVAL160
ok

MHASH_RIPEMD160
ok

MHASH_GOST
ok

Bus error (core dumped)



[2010-02-10 19:06:50] geissert at debian dot org

Description:

ext/hash/hash_tiger.c's TigerFinalize makes an unaligned memory access
at:

tiger_compress(context->passes, ((php_hash_uint64 *)
context->buffer), context->state);







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



#34871 [Opn->WFx]: php isapi does not impersonate app. pool user

2010-02-12 Thread pajoye
 ID:   34871
 Updated by:   paj...@php.net
 Reported By:  giunta dot gaetano at sea-aeroportimilano dot it
-Status:   Open
+Status:   Wont fix
 Bug Type: Feature/Change Request
-Operating System: windows 2003
+Operating System: windows
-PHP Version:  4.4.0
+PHP Version:  *
 New Comment:

Use fastcgi for IIS.


Previous Comments:


[2010-02-12 19:03:20] alone_girl_1607 at hotmail dot com

Give please. In an industrial society which confuses work and
productivity, the necessity of producing has always been an enemy of the
desire to create. Help me! It has to find sites on the: Print a
brochure. I found only this - http://www.medialog.no/Members/BrochurePrinting/discount-brochure-printing";>discount
brochure printing. Most textual was the sedan of a two printing
steep and familiar first procession ridge in the exercise enough filled
by gimbels which, guaranteeing to a customer specialty number, affirmed
500 winds and 2,000 troops per lot at its consulate, brochure printing.
Brochure printing, only before carson's change, she and freeman ordered
copiers of writers. With best wishes :mad:, Elysia from Ecuador.



[2005-11-02 11:03:56] giunta dot gaetano at sea-aeroportimilano dot it

I tried to change every single bit of IIS and PHP configuration to my
best, but of course I cannot be 100% sure...

The hint that pointed me to file a bug was the aforementioned MS
technet article, that explicitly states that IIS apps must call the
RevertToSelf function, and I could find no trace of that call in the
ISAPI source dir.

PS: as a side note: 'impersonation' as mentioned in the php docs looks
to be the reverse process of what I am trying to accomplish: one case is
for websites that have guest access disabled and the scripts have to run
with the privileges of the single user account used to log in into the
website, the other is for websites with guest access enabled and the
scripts have to run with app. pool account instead of iis guest account.



[2005-11-01 22:27:11] sni...@php.net

Are you sure you're doing it the right way (tm) ?




[2005-10-14 15:12:38] giunta dot gaetano at sea-aeroportimilano dot it

Quick test:
Anonymous access for IIS set to IUSR_XXX; App Pool user set to
IWAM_XXX; set a .txt file permissions to 'read access only for IWAM_XXX'
and called readfile() on it.



[2005-10-14 15:04:03] w...@php.net

How did you determine that it isn't impersonating?




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

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



#50999 [Com]: unaligned memory access in Zend/zend_API.c

2010-02-12 Thread geissert at debian dot org
 ID:   50999
 Comment by:   geissert at debian dot org
 Reported By:  geissert at debian dot org
 Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: linux ia64
 PHP Version:  5.3.1
 New Comment:

Still present


Previous Comments:


[2010-02-12 17:16:18] j...@php.net

Please try using this snapshot:

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

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





[2010-02-10 20:59:26] geissert at debian dot org

Failed test: ext/dba/tests/dba_cdb_read.phpt log:
 EXPECTED OUTPUT
database handler: cdb
7NNN
=1234
#1122
?1212314
#1212314
=1231324
 ACTUAL OUTPUT
database handler: cdb
7NNN
=1234
#1122
?1212314
#1212314
=Bus error (core dumped)
 FAILED



[2010-02-10 19:12:28] geissert at debian dot org

Description:

There's an unaligned memory access on zend_parse_arg_impl():

*p = Z_LVAL_PP(arg);







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



#51003 [Com]: unaligned memory access in ext/hash/hash_tiger.c

2010-02-12 Thread geissert at debian dot org
 ID:   51003
 Comment by:   geissert at debian dot org
 Reported By:  geissert at debian dot org
 Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: linux ia64
 PHP Version:  5.3.1
 New Comment:

Still present


Previous Comments:


[2010-02-12 17:14:18] j...@php.net

Please try using this snapshot:

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

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





[2010-02-10 21:03:57] geissert at debian dot org

Description:

There's an unaligned memory access on PHP_TIGERUpdate():

tiger_compress(context->passes, ((const php_hash_uint64 *)
context->buffer), context->state);

Failed test ext/hash/tests/hash_file_basic1.phpt

Actual result:
--
*** Testing hash_file() : basic functionality ***
adler32: ff87222e
crc32: 61664d33
gost: d9e65f0c0c2ef944e4f8a01f4a46365c4f33a2853756878182a7f03e1490a4cd
haval128,3: 8bb81269aca8b7f87829020d76a4e841
md2: 70f791c0d8fa9edd7d08e32fcba8c354
md4: a9d034b16bb290c57a645afd6f14cd3b
md5: 704bf818448f5bbb94061332d2c889aa
ripemd128: d02a5f320a11c54c7d51f933b0bd8471
ripemd160: 3ff296ca6314313af3ed0437c8fc0ebbd3242d3b
ripemd256:
0edd779587c11cf3278b264251eb37529832fb207121cd45dd95002e48a8
ripemd320:
bf162fa2ff20491b3016c5d8190f8ee47d7dcda8c38eaf6779349a243a029d275eec9adf16ec1b35
sha1: 8529b266611e3bd0d208fd9614653c2a8f23d0fe
sha256:
a0f5702fa5d3670b80033d668e8732b70550392abb53841355447f8bb0f72245
sha384:
a35d875ed96d94b6452acad910f97978200faa2398d8a0e6b9cffa33704c3809e3d2e5b0d63700d8f32a0716e7d2d528
sha512:
1f42adaf938fbf136e381b164bae5f984c7f9fe60c82728bd889c14f187c7d63e81a0305a1731c7e0a8f3ed9fd2ec92a3833a93502bdf269532601f0b8e2bab0
snefru:
d414b2345d3e7fa1a31c044cf334bfc1fec24d89e464411998d579d24663895f
Bus error (core dumped)





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



#34871 [Com]: php isapi does not impersonate app. pool user

2010-02-12 Thread alone_girl_1607 at hotmail dot com
 ID:   34871
 Comment by:   alone_girl_1607 at hotmail dot com
 Reported By:  giunta dot gaetano at sea-aeroportimilano dot it
 Status:   Open
 Bug Type: Feature/Change Request
 Operating System: windows 2003
 PHP Version:  4.4.0
 New Comment:

Give please. In an industrial society which confuses work and
productivity, the necessity of producing has always been an enemy of the
desire to create. Help me! It has to find sites on the: Print a
brochure. I found only this - http://www.medialog.no/Members/BrochurePrinting/discount-brochure-printing";>discount
brochure printing. Most textual was the sedan of a two printing
steep and familiar first procession ridge in the exercise enough filled
by gimbels which, guaranteeing to a customer specialty number, affirmed
500 winds and 2,000 troops per lot at its consulate, brochure printing.
Brochure printing, only before carson's change, she and freeman ordered
copiers of writers. With best wishes :mad:, Elysia from Ecuador.


Previous Comments:


[2005-11-02 11:03:56] giunta dot gaetano at sea-aeroportimilano dot it

I tried to change every single bit of IIS and PHP configuration to my
best, but of course I cannot be 100% sure...

The hint that pointed me to file a bug was the aforementioned MS
technet article, that explicitly states that IIS apps must call the
RevertToSelf function, and I could find no trace of that call in the
ISAPI source dir.

PS: as a side note: 'impersonation' as mentioned in the php docs looks
to be the reverse process of what I am trying to accomplish: one case is
for websites that have guest access disabled and the scripts have to run
with the privileges of the single user account used to log in into the
website, the other is for websites with guest access enabled and the
scripts have to run with app. pool account instead of iis guest account.



[2005-11-01 22:27:11] sni...@php.net

Are you sure you're doing it the right way (tm) ?




[2005-10-14 15:12:38] giunta dot gaetano at sea-aeroportimilano dot it

Quick test:
Anonymous access for IIS set to IUSR_XXX; App Pool user set to
IWAM_XXX; set a .txt file permissions to 'read access only for IWAM_XXX'
and called readfile() on it.



[2005-10-14 15:04:03] w...@php.net

How did you determine that it isn't impersonating?




[2005-10-14 14:56:53] giunta dot gaetano at sea-aeroportimilano dot it

Description:

I had a very hard time trying to figure out which user will be used to
actually run the php processes on IIS 6+php isapi.

The server is configured in non-IIS5-compliant security mode, and php
runs fine, but it keeps using the windows user account configured for
anonymous website access, instead of the user account set for the
Application Pool connected to the website in question.

All MS docs state that web apps run under the user account/using the
privileges of the account defined for the App. Pool (by default NETWORK
SERVICE).

User comments on the online manual vary wildly: some users seem to have
had success in using the app. pool user, some using the anonymous
connection user.

Docs at
http://www.microsoft.com/technet/prodtechnol/windowsserver2003/technologies/webapp/iis/appisoa.mspx#EGAA
indicate that in order for the web app to exibhit this behaviour, it
has to call the he Win32API RevertToSelf function, of which I sould
finnd no trace in the php source code, except for the FCGI module...

Am I missing something?






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



#51023 [Com]: ext/filter/tests/046.phpt fails, does not detect int overflow

2010-02-12 Thread geissert at debian dot org
 ID:  51023
 Comment by:  geissert at debian dot org
 Reported By: geissert at debian dot org
 Status:  Feedback
 Bug Type:Filter related
 PHP Version: 5.3.1
 New Comment:

Still present.
What's the point of checking the code myself and describing the bug and
the fix if you are going to ask me to try the latest svn which contains
the same code on the file where the bug occurs?


Previous Comments:


[2010-02-12 16:13:42] j...@php.net

Please try using this snapshot:

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

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





[2010-02-11 23:31:02] geissert at debian dot org

Description:

The filter fails to detect an integer overflow and passes the
FILTER_VALIDATE_INT test. The problem is caused because
php_filter_parse_int uses a long to detect the overflow, which of course
doesn't have the same size of an integer.

This can be fixed by making ctx_value an integer in both
php_filter_parse_int and php_filter_int (and for correctness, not
setting Z_TYPE_P(value) to IS_LONG).


Reproduce code:
---
// the current test:
$s = sprintf("%d", PHP_INT_MAX);
var_dump(is_long(filter_var($s, FILTER_VALIDATE_INT)));

$s = sprintf("%.0f", PHP_INT_MAX+1);
var_dump(filter_var($s, FILTER_VALIDATE_INT));

$s = sprintf("%d", -PHP_INT_MAX);
var_dump(is_long(filter_var($s, FILTER_VALIDATE_INT)));

Expected result:

bool(true)
bool(false)
bool(true)


Actual result:
--
bool(true)
int(-2147483648)
bool(true)





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



#51008 [Com]: Zend/tests/bug45877.phpt fails

2010-02-12 Thread geissert at debian dot org
 ID:   51008
 Comment by:   geissert at debian dot org
 Reported By:  geissert at debian dot org
 Status:   Feedback
 Bug Type: *General Issues
 Operating System: debian sid
 PHP Version:  5.3.1
 New Comment:

It fails for me with 5.3.1 on i686, ia64, s390, alpha, powerpc, x86_64,
etc. Even on those running kfreebsd.
It also fails with the latest 5.3 svn on ia64 (haven't built it on any
other arch.)


Previous Comments:


[2010-02-12 17:02:47] j...@php.net

In what kind of environment does it fail? It works fine for me in both
32bit and 64bit systems. (using latest SVN checkout of course :)



[2010-02-11 01:54:21] geissert at debian dot org

Description:

The test fails 

Reproduce code:
---



Expected result:

array(2) {
  [2147483647]=>
  int(1)
  [-2147483648]=>
  int(1)
  ["2147483648"]=>
  int(1)
}


Actual result:
--
array(2) {
  [2147483647]=>
  int(1)
  [-2147483648]=>
  int(1)
}






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



#50981 [Com]: CachingIterator::hasNext() does not return correct value in some cases

2010-02-12 Thread clarity1285 at gmail dot com
 ID:   50981
 Comment by:   clarity1285 at gmail dot com
 Reported By:  clarity1285 at gmail dot com
 Status:   Feedback
 Bug Type: SPL related
 Operating System: Mac OS X
 PHP Version:  5.3.1
 New Comment:

Tested with PHP 5.3.3-dev snapshot provided, and the issue is still 
reproducible.


Previous Comments:


[2010-02-12 17:23:50] j...@php.net

Please try using this snapshot:

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

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





[2010-02-12 17:04:55] aleksey dot v dot korzun at gmail dot com

I'm experiencing the same issue.



[2010-02-09 23:05:48] clarity1285 at gmail dot com

Description:

When there are 11 total items and you use a LimitIterator to get the 
first 10, CachingIterator::hasNext() returns false even though there
are 
more than 10 items in the initial set.

If there are 12 total items it works as expected.

Reproduce code:
---
$items = new ArrayObject(range(1,11));

echo 'there are ' . $items->count() . ' total items' . "\r\n";

$cachingIterator = new CachingIterator($items->getIterator());

$limitIterator = new LimitIterator($cachingIterator, 0, 10);

$i = 0;
foreach ($limitIterator as $item) {
++$i;
}

echo 'first page has ' . $i . ' items' . "\r\n";

if ($cachingIterator->hasNext()) {
echo 'there is a next page';
} else {
echo 'there is no next page';
}

Expected result:

The code should output:

there are 11 total items 
first page has 10 items 
there is a next page

Actual result:
--
The code outputs:

there are 11 total items 
first page has 10 items 
there is no next page





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



#51015 [Bgs]: Array keys can not be used to get values

2010-02-12 Thread nat at search dot ch
 ID:   51015
 User updated by:  nat at search dot ch
 Reported By:  nat at search dot ch
 Status:   Bogus
 Bug Type: *General Issues
 Operating System: Linux #1 SMP 2009-08-15 17:53:59
 PHP Version:  5.3.1
 New Comment:

$choices is a variable of a new kind. It is no:
- Boolean
- Integer
- Floating point number
- String
- Array
- Object
It is an inconsequence with the rest of php.
I think this case should be considered in future versions.


Previous Comments:


[2010-02-12 16:45:44] j...@php.net

RTFM:

http://php.net/array#language.types.array.casting

"If an object is converted to an array, the result is an array whose
elements are the object's properties. The keys are the member variable
names, with a few notable exceptions: integer properties are
unaccessible.."

And you could also access those directly without casting anyway, like
this:

var_dump($model->choices->{1});






[2010-02-11 13:57:10] nat at search dot ch

Description:

In an associative array with number as text keys, the keys can not be
used to get the values. "Foreach" works.

  var_dump($choices);  
// array(2) { ["1"]=>  array(2) { [0]=>  string(1) "0" [1]=>  string(1)
"1" } ["0"]=>  array(2) { [0]=>  string(1) "0" [1]=>  string(1) "1" } }

  var_dump($choices['1']); // NULL
  var_dump($choices[1]);   // NULL
  var_dump($choices["1"]); // NULL
  var_dump($choices->{1}); // NULL
  var_dump($choices->{'1'});//NULL
  var_dump($choices['0']);  //NULL
  var_dump($choices[0]);//NULL

 foreach ($choices as $k => $v) {
var_dump($k, $v);
  }

// string(1) "1" array(2) { [0]=> string(1) "0" [1]=> string(1) "1" }
// string(1) "0" array(2) { [0]=> string(1) "0" [1]=> string(1) "1" }


Reproduce code:
---
$db_data_model='{"events":{"1":"film","0":"avatar"},"times":{"0":"2010-10-09
08:00","2":"2010-10-09
11:00","3":"2010-09-09"},"choices":{"1":["0","1"],"0":["0","1"]}}';
$model = json_decode($db_data_model);
$choices = (array)$model->choices;
var_dump($choices);
var_dump($choices['1']); // NULL
var_dump($choices[1]);   // NULL
var_dump($choices->{1}); // NULL
var_dump($choices->{'1'});//NULL

foreach ($choices as $k => $v) {
var_dump($k, $v);
}



Expected result:

var_dump($choices['1']);

// array(2) { [0]=> string(1) "0" [1]=> string(1) "1" }

var_dump($choices['0']);

// array(2) { [0]=> string(1) "0" [1]=> string(1) "1" }

Actual result:
--
var_dump($choices['1']);

// NULL

var_dump($choices['0']);

// NULL





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



#51022 [Com]: getservbyname_basic.phpt has incorrect description and misses a skip case

2010-02-12 Thread geissert at debian dot org
 ID:   51022
 Comment by:   geissert at debian dot org
 Reported By:  geissert at debian dot org
 Status:   Feedback
 Bug Type: Network related
 Operating System: debian sid
 PHP Version:  5.3.1
 New Comment:

Maybe because it says:
Test function getservby*port*() by *calling it more than or less than
its expected arguments*

The test does nothing of that :)

As to why /etc/services (and friends) wouldn't exist: because it is
only required for networking (not going to strongly push that change,
though.)


Previous Comments:


[2010-02-12 16:26:03] j...@php.net

Why would you not have /etc/services and how is the description wrong?
(patches are welcome..)



[2010-02-11 21:29:55] geissert at debian dot org

Description:

The description of
ext/standard/tests/general_functions/getservbyname_basic.phpt is
incorrect, as that's not really what the test is about.
Additionally, a SKIP section should be added to skip the test if
/etc/services does not exist.







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



#50969 [Bgs]: operator overloading for classes

2010-02-12 Thread sylvain at abstraction dot fr
 ID:   50969
 User updated by:  sylvain at abstraction dot fr
 Reported By:  sylvain at abstraction dot fr
 Status:   Bogus
 Bug Type: Feature/Change Request
 Operating System: all
 PHP Version:  5.3.2RC1
 New Comment:

I don't disagree, I was just asking for good reasons to not implement
it and "it's not readable" or "it could get funny" are not according to
me.

Regards.


Previous Comments:


[2010-02-12 16:45:45] ras...@php.net

Sorry, this will never happen.  Basic operators need to be 
deterministic in PHP.  You can disagree if you like, but that isn't 
going to change anything.



[2010-02-12 13:28:30] sylvain at abstraction dot fr

Well it is maybe implemented but it's beta and has not been updated 
for over 3 years. It is not usable in a 
production environment.

Regarding your point that it is not readable, objects implementing 
Iterator can be used with the foreach 
statement (which is an overloading) and for objects with multiples 
propertiesn you don't know what is done 
unless you read the code.

So, I don't see why we could not have overator overloading already 
having foreach overloading.

Things can get "funny" with overloading, yes, but that's not a reason 
to not implement it. You can't state you 
won't allow something because some people will not use it correctly, 
in that case, you allow nothing and you 
don't implement a dynamically weak typed language. It is up to the 
developer to secure its implementation. You 
must have a little faith in him.

Here an exemple of what I have in mind based on the Iterator model :

interface OperatorOverloading
{
public function __add($object);
public function __substract($object);
public function __multiply($object);
public function __divide($object);
public function __increment();
public function __decrement();
}

class foo implements OperatorOverloading
{
private $anynumber = 0;

public function __add($object)
{
if (!$object instanceof __CLASS__)
{
throw new Exception('Come on !!!');
}

$return = new foo();
$return->anynumber = $this->anynumber + $object-
>anynumber;

return $return;
}

public function __increment()
{
$this->anynumber++;
}

public function __decrement()
{
$this->anynumber--;
}

public function __substract($object)
{
throw new Exception('not implemented');
}

public function __divide($object)
{
throw new Exception('not implemented');
}

public function __multiply($object)
{
throw new Exception('not implemented');
}
}

Regards.



[2010-02-08 23:54:47] johan...@php.net

Well it is implemented, as you can see when following the link, I
myself once created a patch to make it a bit nicer in syntax but it will
never be implemented (as far as never goes)

And well the issue, in the most simple form, is something like this:

function foo() {
return bar() + baz();
}

In today's world during are view you can say "this will return a
numeric value"with operator overloading you can say "this will return
something or maybe fail"

Becomes especially "funny" with

return bar() + 4;

Sure there's convention and comments and things but that won't help and
you can always do

   return bar()->add(baz());

or

   return someclass::add(bar(), baz());

which makes the intention clear. Yes $a + $b + $c + $d might be bit
nicer to read than the long form - but only as long as you know what
types you have ...



[2010-02-08 23:15:17] sylvain at abstraction dot fr

I'm not particularly aware of operator overloading in other language
but I don't see why it would be less readable in PHP than in any other
language as the only way to know what is happening is to read the code
of the method overloading the operator.

Anyhow, do I have to take as official PHP Team position that you won't
implement it ?



[2010-02-08 22:59:25] johan...@php.net

Operator overloading in a dynamically weak typed language is bad as
reading code gives no information what's happening. If you really want
it go to http://pecl.php.net/operator maybe that still works.



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug repor

#50915 [Opn->Fbk]: ldap extension with Solaris libldap patched for ldap urls

2010-02-12 Thread jani
 ID:   50915
 Updated by:   j...@php.net
 Reported By:  strube at physik3 dot gwdg dot de
-Status:   Open
+Status:   Feedback
 Bug Type: LDAP related
 Operating System: Solaris 10
 PHP Version:  5.2.12
 New Comment:

Ever heard of pastebin.com ? Try that.


Previous Comments:


[2010-02-12 16:39:11] strube at physik3 dot gwdg dot de

> No feedback was provided for this bug for over a week
I have simply been waiting for a reply to my question from 3 Feb 9:13am
UTC. It may seem trivial to you, but I am not sure what to do. Must I
set "Version" to 5.3.1? Can the patch not be uploaded but only a link
given to a file on our local webserver (which will not exist forever)?
(BTW, my password has not been working. I got it sent to me but it was
changed - definitely not by me!)



[2010-02-03 09:13:01] strube at physik3 dot gwdg dot de

>Please provide patches (links) against PHP_5_3 and trunk.
How must I proceed to do so?



[2010-02-02 17:14:49] paj...@php.net

hi,

Please provide patches (links) against PHP_5_3 and trunk.

Cheers,



[2010-02-02 17:08:00] strube at physik3 dot gwdg dot de

Description:

The PHP extension "ldap" can be build with the native Solaris 10
libldap and works well, except that it does not understand URL format
(ldap://host, ldaps://host). I made a patch for this, based on testing
for _SOLARIS_SDK (defined in /usr/include/ldap.h), which might also work
for other NSLDAP variants. How can I upload this?
(The line numbers seem not to have changed at least from 5.2.10 to
5.3.1.)






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



#50970 [Opn->Fbk]: force convert a string into int using (int) or intval() cause value truncate

2010-02-12 Thread jani
 ID:   50970
 Updated by:   j...@php.net
 Reported By:  zhangsilly at gmail dot com
-Status:   Open
+Status:   Feedback
 Bug Type: Scripting Engine problem
 Operating System: Windows XP
 PHP Version:  5.2.12
 New Comment:

Please try using this snapshot:

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

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

Works fine for me with Linux..


Previous Comments:


[2010-02-10 01:48:54] zhangsilly at gmail dot com

this is cause by strtol, used in the ZEND_API convert_to_long_base(zval

*op, int base), which is defined in stdlib.h.

strtol will always return LONG_MAX if the string stands for a
number 
which is larger than LONG_MAX.

I'am afraid no matter zend_parse_parameters and convert_to_long,
the  
should have the same behavior.

This whill cause a situation that when i pass a string which is 
readed from file or socket to long2ip, long2ip($str) is right but 
long2ip((int)$str) will be failed.



[2010-02-09 01:29:31] zhangsilly at gmail dot com

Description:

use (int) or intval() to convert a string into integer in userland, if

bigger than 2147483647, this will result a truncate, the value will 
always be 2147483647.

 but use zend_parse_parameters to parse the string as a long 
arguement, is do give the correct value in nagtive format



Reproduce code:
---
/** 
* assert failure 
* (int)3740925952 result is -554041344 
* (int)'3740925952' result is 2147483647 
*/ 
assert((int)3740925952 == (int)'3740925952'); 

Expected result:

assert should be succeed

Actual result:
--
assert failure





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



#50977 [Opn->Fbk]: imap_headerinfo Address buffer overflow

2010-02-12 Thread jani
 ID:   50977
 Updated by:   j...@php.net
 Reported By:  lokitek at gmail dot com
-Status:   Open
+Status:   Feedback
-Bug Type: Reproducible crash
+Bug Type: IMAP related
 Operating System: CentOS 5.4
 PHP Version:  5.2.12


Previous Comments:


[2010-02-10 20:26:50] lokitek at gmail dot com

drop centOS isn't all that easy - What would you recommend instead? ;)

I'll update c-client and will let you know.
Thanks!



[2010-02-10 16:24:41] paj...@php.net

Yes, or you may drop centos as well, known to have outdated versions of
everything. Please let us know if it still happens once you have a
decent version if c-client.



[2010-02-10 16:06:17] lokitek at gmail dot com

The c-client library is:
libc-client 2004g-2.2.1 

2004 sounds somewhat old, should I try to find an upgrade for it?



[2010-02-10 00:16:36] paj...@php.net

I'm not asking which PHP version you use (try 5.2.12, instead of
5.2.11) but which c-client library you use. c-client is the imap library
used by the php imap extension.



[2010-02-10 00:12:41] lokitek at gmail dot com

I don't think that it makes a huge difference, but I just realized that
I'm on php-5.2.11 and using php-imap-5.2.11

If this isn't what you're after, just let me know and I can do a bit of
debugging all around.

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
http://bugs.php.net/50977

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



#50981 [Opn->Fbk]: CachingIterator::hasNext() does not return correct value in some cases

2010-02-12 Thread jani
 ID:   50981
 Updated by:   j...@php.net
 Reported By:  clarity1285 at gmail dot com
-Status:   Open
+Status:   Feedback
 Bug Type: SPL related
 Operating System: Mac OS X
 PHP Version:  5.3.1
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2010-02-12 17:04:55] aleksey dot v dot korzun at gmail dot com

I'm experiencing the same issue.



[2010-02-09 23:05:48] clarity1285 at gmail dot com

Description:

When there are 11 total items and you use a LimitIterator to get the 
first 10, CachingIterator::hasNext() returns false even though there
are 
more than 10 items in the initial set.

If there are 12 total items it works as expected.

Reproduce code:
---
$items = new ArrayObject(range(1,11));

echo 'there are ' . $items->count() . ' total items' . "\r\n";

$cachingIterator = new CachingIterator($items->getIterator());

$limitIterator = new LimitIterator($cachingIterator, 0, 10);

$i = 0;
foreach ($limitIterator as $item) {
++$i;
}

echo 'first page has ' . $i . ' items' . "\r\n";

if ($cachingIterator->hasNext()) {
echo 'there is a next page';
} else {
echo 'there is no next page';
}

Expected result:

The code should output:

there are 11 total items 
first page has 10 items 
there is a next page

Actual result:
--
The code outputs:

there are 11 total items 
first page has 10 items 
there is no next page





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



#50982 [Opn->Asn]: incorrect assumption of PAGE_SIZE size

2010-02-12 Thread jani
 ID:  50982
 Updated by:  j...@php.net
 Reported By: geissert at debian dot org
-Status:  Open
+Status:  Assigned
-Bug Type:*Compile Issues
+Bug Type:Compile Failure
 PHP Version: 5.3.1
-Assigned To: 
+Assigned To: dmitry
 New Comment:

Related to bug #48034 

Dmitry, please check this out.



Previous Comments:


[2010-02-09 23:26:25] geissert at debian dot org

Description:

If sys/mman.h does not define PAGE_SIZE there's an incorrect assumption
that it is 4096. This can have multiple side effects.

At Debian we are going to use the following patch:
http://git.debian.org/?p=pkg-php/php.git;a=blob;f=debian/patches/page_size_fixes.patch;h=f24b732ff6349101e1cee560b581081ca74d717f;hb=HEAD

There's also a logical bug where PAGE_SIZE could not be defined at all
but still used, but I'm not addressing that one.







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



#50995 [Opn->Fbk]: segfault with Zend Memory Manager = enabled

2010-02-12 Thread jani
 ID:   50995
 Updated by:   j...@php.net
 Reported By:  valters at videinfra dot com
-Status:   Open
+Status:   Feedback
-Bug Type: Unknown/Other Function
+Bug Type: Scripting Engine problem
 Operating System: Debian Lenny
 PHP Version:  5.2.12
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2010-02-11 22:42:49] aigors at inbox dot lv

The workaround has been found to the issue. The segmentation fault
disappeared when the class property visibility was changed from
protected to public or the __wakeup method was changed – the nullifying
of the same property was removed.



[2010-02-10 15:41:35] valters at videinfra dot com

Description:

./configure --prefix=/usr/local/php5.2 --sysconfdir=/etc
--with-apxs2=/usr/local/apache/bin/apxs
--with-config-file-path=/etc/php/apache2-php5
--with-config-file-scan-dir=/etc/php/apache2-php5/ext-active
--without-pear --enable-bcmath --enable-calendar --with-curl
--enable-exif --enable-ftp --with-gettext --with-gmp --enable-mbstring
--with-mcrypt --with-mhash --with-openssl --with-openssl-dir
--with-pgsql --with-pspell --enable-soap --enable-sockets --with-xmlrpc
--with-xsl --enable-zip --with-zlib --enable-dba --with-db4 --with-gdbm
--with-freetype-dir --with-jpeg-dir --with-png-dir --with-gd --with-imap
--with-imap-ssl --with-ldap --with-pdo-dblib --with-pdo-pgsql
--with-pdo-sqlite --with-readline --with-sqlite --enable-sqlite-utf8
--with-kerberos --disable-ipv6

there is no segfault with --enable-debug and it seems that this crash
happens after the end of the script. The crash happens when php is
compiled with Zend Memory Manager = enabled 
Server version: Apache/2.2.14 (Unix)
[notice] child pid 8480 exit signal Segmentation fault (11)


Actual result:
--
0xb79d7ffa in zend_mm_remove_from_free_list (heap=, mm_block=0x8f35784) at /root/php-5.2.12/Zend/zend_alloc.c:822
822 ZEND_MM_CHECK_TREE(mm_block);
(gdb) bt
#0  0xb79d7ffa in zend_mm_remove_from_free_list (heap=, mm_block=0x8f35784) at /root/php-5.2.12/Zend/zend_alloc.c:822
#1  0xb79d8131 in _zend_mm_free_int (heap=0x8965fd8, p=) at /root/php-5.2.12/Zend/zend_alloc.c:1979
#2  0xb79fbe5a in zend_hash_destroy (ht=0x8f36c64) at
/root/php-5.2.12/Zend/zend_hash.c:531
#3  0xb79f18d5 in _zval_dtor_func (zvalue=0x8f42320) at
/root/php-5.2.12/Zend/zend_variables.c:42
#4  0xb79e5460 in _zval_ptr_dtor (zval_ptr=0x8f41fc0) at
/root/php-5.2.12/Zend/zend_variables.h:35
#5  0xb79fbe2e in zend_hash_destroy (ht=0x8f36e7c) at
/root/php-5.2.12/Zend/zend_hash.c:526
#6  0xb7a0bcb3 in zend_object_std_dtor (object=0x8f41460) at
/root/php-5.2.12/Zend/zend_objects.c:45
#7  0xb7a0bce2 in zend_objects_free_object_storage (object=0x8f41460)
at /root/php-5.2.12/Zend/zend_objects.c:122
#8  0xb7a0f018 in zend_objects_store_del_ref_by_handle (handle=51) at
/root/php-5.2.12/Zend/zend_objects_API.c:211
#9  0xb7a0f038 in zend_objects_store_del_ref (zobject=0x8f4094c) at
/root/php-5.2.12/Zend/zend_objects_API.c:169
#10 0xb79e5460 in _zval_ptr_dtor (zval_ptr=0x91dcf74) at
/root/php-5.2.12/Zend/zend_variables.h:35
#11 0xb79fbe2e in zend_hash_destroy (ht=0x91dcf10) at
/root/php-5.2.12/Zend/zend_hash.c:526
#12 0xb7a0bcb3 in zend_object_std_dtor (object=0x91dceb8) at
/root/php-5.2.12/Zend/zend_objects.c:45
#13 0xb7a0bce2 in zend_objects_free_object_storage (object=0x91dceb8)
at /root/php-5.2.12/Zend/zend_objects.c:122
#14 0xb7a0f018 in zend_objects_store_del_ref_by_handle (handle=102) at
/root/php-5.2.12/Zend/zend_objects_API.c:211
#15 0xb7a0f038 in zend_objects_store_del_ref (zobject=0x91dcea0) at
/root/php-5.2.12/Zend/zend_objects_API.c:169
#16 0xb79e5460 in _zval_ptr_dtor (zval_ptr=0x91dd028) at
/root/php-5.2.12/Zend/zend_variables.h:35
#17 0xb79fbe2e in zend_hash_destroy (ht=0x91dcb00) at
/root/php-5.2.12/Zend/zend_hash.c:526
#18 0xb79f18d5 in _zval_dtor_func (zvalue=0x91dbff4) at
/root/php-5.2.12/Zend/zend_variables.c:42
#19 0xb79e5460 in _zval_ptr_dtor (zval_ptr=0x9113624) at
/root/php-5.2.12/Zend/zend_variables.h:35
#20 0xb79fbe2e in zend_hash_destroy (ht=0x91dc424) at
/root/php-5.2.12/Zend/zend_hash.c:526
#21 0xb7a0bcb3 in zend_object_std_dtor (object=0x911424c) at
/root/php-5.2.12/Zend/zend_objects.c:45
#22 0xb7a0bce2 in zend_objects_free_object_storage (object=0x911424c)
at /root/php-5.2.12/Zend/zend_objects.c:122
#23 0xb7a0f018 in zend_objects_store_del_ref_by_handle (handle=97) at
/root/php-5.2.12/Zend/zend_objects_API.c:211
#24 0xb7a0f038 in zend_objects_store_del_ref (zobject=0x9108a8c) at
/root/php-5.2.12/Zend/zend_objects_API.c:169
#25 0xb79e5460 in _zval_ptr_dtor (zval_ptr=0x91dcae0) at
/root/php-5.2.12/Zend/zend_variables.h:35
#26 0xb79fbe2e in zend_hash_destroy (ht=0x91dc3d4

#50998 [Opn->Fbk]: unaligned memory access in hash_tiger.c

2010-02-12 Thread jani
 ID:   50998
 Updated by:   j...@php.net
 Reported By:  geissert at debian dot org
-Status:   Open
+Status:   Feedback
 Bug Type: hash related
 Operating System: linux ia64
 PHP Version:  5.3.1
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2010-02-10 21:06:30] geissert at debian dot org

Failed test: ext/hash/tests/mhash_001.phpt

Output:
MHASH_MD5
ok

MHASH_SHA1
ok

MHASH_HAVAL256
ok

MHASH_HAVAL192
ok

MHASH_HAVAL224
ok

MHASH_HAVAL160
ok

MHASH_RIPEMD160
ok

MHASH_GOST
ok

Bus error (core dumped)



[2010-02-10 19:06:50] geissert at debian dot org

Description:

ext/hash/hash_tiger.c's TigerFinalize makes an unaligned memory access
at:

tiger_compress(context->passes, ((php_hash_uint64 *)
context->buffer), context->state);







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



#50999 [Opn->Fbk]: unaligned memory access in Zend/zend_API.c

2010-02-12 Thread jani
 ID:   50999
 Updated by:   j...@php.net
 Reported By:  geissert at debian dot org
-Status:   Open
+Status:   Feedback
-Bug Type: Reproducible crash
+Bug Type: Scripting Engine problem
 Operating System: linux ia64
 PHP Version:  5.3.1
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2010-02-10 20:59:26] geissert at debian dot org

Failed test: ext/dba/tests/dba_cdb_read.phpt log:
 EXPECTED OUTPUT
database handler: cdb
7NNN
=1234
#1122
?1212314
#1212314
=1231324
 ACTUAL OUTPUT
database handler: cdb
7NNN
=1234
#1122
?1212314
#1212314
=Bus error (core dumped)
 FAILED



[2010-02-10 19:12:28] geissert at debian dot org

Description:

There's an unaligned memory access on zend_parse_arg_impl():

*p = Z_LVAL_PP(arg);







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



#51000 [Fbk]: unaligned memory access in ext/hash/hash_tiger.c

2010-02-12 Thread jani
 ID:   51000
 Updated by:   j...@php.net
 Reported By:  geissert at debian dot org
 Status:   Feedback
 Bug Type: hash related
 Operating System: linux ia64
 PHP Version:  5.3.1
 New Comment:

Please try using this snapshot:

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

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

Sorry, wrong branch in previous post. :)


Previous Comments:


[2010-02-12 17:15:17] j...@php.net

Please try using this snapshot:

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

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





[2010-02-10 19:24:03] geissert at debian dot org

Description:

There's an unaligned memory access on PHP_TIGERUpdate():

context->passed += 512;







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



#51000 [Opn->Fbk]: unaligned memory access in ext/hash/hash_tiger.c

2010-02-12 Thread jani
 ID:   51000
 Updated by:   j...@php.net
 Reported By:  geissert at debian dot org
-Status:   Open
+Status:   Feedback
-Bug Type: Reproducible crash
+Bug Type: hash related
 Operating System: linux ia64
 PHP Version:  5.3.1
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2010-02-10 19:24:03] geissert at debian dot org

Description:

There's an unaligned memory access on PHP_TIGERUpdate():

context->passed += 512;







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



#51003 [Opn->Fbk]: unaligned memory access in ext/hash/hash_tiger.c

2010-02-12 Thread jani
 ID:   51003
 Updated by:   j...@php.net
 Reported By:  geissert at debian dot org
-Status:   Open
+Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: linux ia64
 PHP Version:  5.3.1
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2010-02-10 21:03:57] geissert at debian dot org

Description:

There's an unaligned memory access on PHP_TIGERUpdate():

tiger_compress(context->passes, ((const php_hash_uint64 *)
context->buffer), context->state);

Failed test ext/hash/tests/hash_file_basic1.phpt

Actual result:
--
*** Testing hash_file() : basic functionality ***
adler32: ff87222e
crc32: 61664d33
gost: d9e65f0c0c2ef944e4f8a01f4a46365c4f33a2853756878182a7f03e1490a4cd
haval128,3: 8bb81269aca8b7f87829020d76a4e841
md2: 70f791c0d8fa9edd7d08e32fcba8c354
md4: a9d034b16bb290c57a645afd6f14cd3b
md5: 704bf818448f5bbb94061332d2c889aa
ripemd128: d02a5f320a11c54c7d51f933b0bd8471
ripemd160: 3ff296ca6314313af3ed0437c8fc0ebbd3242d3b
ripemd256:
0edd779587c11cf3278b264251eb37529832fb207121cd45dd95002e48a8
ripemd320:
bf162fa2ff20491b3016c5d8190f8ee47d7dcda8c38eaf6779349a243a029d275eec9adf16ec1b35
sha1: 8529b266611e3bd0d208fd9614653c2a8f23d0fe
sha256:
a0f5702fa5d3670b80033d668e8732b70550392abb53841355447f8bb0f72245
sha384:
a35d875ed96d94b6452acad910f97978200faa2398d8a0e6b9cffa33704c3809e3d2e5b0d63700d8f32a0716e7d2d528
sha512:
1f42adaf938fbf136e381b164bae5f984c7f9fe60c82728bd889c14f187c7d63e81a0305a1731c7e0a8f3ed9fd2ec92a3833a93502bdf269532601f0b8e2bab0
snefru:
d414b2345d3e7fa1a31c044cf334bfc1fec24d89e464411998d579d24663895f
Bus error (core dumped)





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



#51002 [Asn]: An int variable is used as size_t in child function

2010-02-12 Thread jani
 ID:   51002
 Updated by:   j...@php.net
 Reported By:  s...@php.net
 Status:   Assigned
 Bug Type: Zip Related
-Operating System: n/a
+Operating System: *
 PHP Version:  5.3.2RC1
 Assigned To:  pajoye
 New Comment:

There is no such OS called 'n/a'.


Previous Comments:


[2010-02-10 20:12:23] johan...@php.net

Assign to maintainer



[2010-02-10 20:07:06] s...@php.net

Description:

In php_zip_add_from_pattern() a pointer to file_stripped_len is passed
to php_based which treats the address as a size_t. If the size of int
differs from the size of size_t then this could cause a memory access
error.

int entry_name_len,file_stripped_len;
...

php_basename(Z_STRVAL_PP(zval_file), Z_STRLEN_PP(zval_file), NULL, 0,
   &basename, (size_t *)&file_stripped_len TSRMLS_CC)

This is related to Rasmus's fix
http://svn.php.net/viewvc?view=revision&revision=294816






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



#51007 [Opn->Csd]: posix_uname{,_basic}.phpt are duplicates and lack handling of domainname

2010-02-12 Thread jani
 ID:   51007
 Updated by:   j...@php.net
 Reported By:  geissert at debian dot org
-Status:   Open
+Status:   Closed
 Bug Type: POSIX related
 Operating System: debian
 PHP Version:  5.3.1
 New Comment:

I nuked the duplicate test. The other fix was already done in SVN..


Previous Comments:


[2010-02-12 17:09:09] s...@php.net

Automatic comment from SVN on behalf of jani
Revision: http://svn.php.net/viewvc/?view=revision&revision=294998
Log: - Removed duplicate tests (bug #51007)



[2010-02-11 00:48:02] geissert at debian dot org

Description:

Both tests test the same functionality and they both miss the case
where the domainname key may exist.

A simple workaround would be to unset($uname['domainname']) on
_basic.phpt and drop the other one.







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



#50981 [Com]: CachingIterator::hasNext() does not return correct value in some cases

2010-02-12 Thread aleksey dot v dot korzun at gmail dot com
 ID:   50981
 Comment by:   aleksey dot v dot korzun at gmail dot com
 Reported By:  clarity1285 at gmail dot com
 Status:   Open
 Bug Type: SPL related
 Operating System: Mac OS X
 PHP Version:  5.3.1
 New Comment:

I'm experiencing the same issue.


Previous Comments:


[2010-02-09 23:05:48] clarity1285 at gmail dot com

Description:

When there are 11 total items and you use a LimitIterator to get the 
first 10, CachingIterator::hasNext() returns false even though there
are 
more than 10 items in the initial set.

If there are 12 total items it works as expected.

Reproduce code:
---
$items = new ArrayObject(range(1,11));

echo 'there are ' . $items->count() . ' total items' . "\r\n";

$cachingIterator = new CachingIterator($items->getIterator());

$limitIterator = new LimitIterator($cachingIterator, 0, 10);

$i = 0;
foreach ($limitIterator as $item) {
++$i;
}

echo 'first page has ' . $i . ' items' . "\r\n";

if ($cachingIterator->hasNext()) {
echo 'there is a next page';
} else {
echo 'there is no next page';
}

Expected result:

The code should output:

there are 11 total items 
first page has 10 items 
there is a next page

Actual result:
--
The code outputs:

there are 11 total items 
first page has 10 items 
there is no next page





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



#51005 [Ana->Bgs]: --without-sqlite3 should be --with-sqlite3

2010-02-12 Thread jani
 ID:  51005
 Updated by:  j...@php.net
 Reported By: geissert at debian dot org
-Status:  Analyzed
+Status:  Bogus
 Bug Type:*Compile Issues
 PHP Version: 5.3.1
 New Comment:

There's neither any bug here or anything wrong with the description
logic. Nor does it affect any working parts. :)


Previous Comments:


[2010-02-11 00:37:10] ras...@php.net

Yes, I am aware of that, but it is --without-sqlite3 there because by 
default if you don't specify anything you get sqlite3 compiled in since

we bundle that library.  So when you do ./configure --help you should 
see --without-sqlite3 as the listed option letting you know to use that

to build PHP without it.



[2010-02-10 23:00:05] geissert at debian dot org

Sorry for not being specific, I was talking about the description on
the m4 file:

PHP_ARG_WITH(sqlite3, whether to enable the SQLite3 extension,
[  --without-sqlite3[=DIR] Do not include SQLite3 support. DIR is the
prefix to
  SQLite3 installation directory.], yes)



[2010-02-10 22:32:35] ras...@php.net

The option is called --with-sqlite3.  That's how autoconf works.  You 
have --enable/--disable and --with/--without switches.  If the feature

is on by default then you use --disable/--without to turn it off.  If 
the feature is off by default, then it is the opposite.  Try it by 
using --with-sqlite3=/some/path

But yes, the yes/no responses are messed up when using these.  



[2010-02-10 22:09:56] geissert at debian dot org

Description:

I just noticed sqlite3's config0.m4 has an inverted logic:

--without-sqlite3 defaults to yes, which instead of NOT including
sqlite3 it _does_ include it (using the bundled copy).

--without-sqlite3=/foo also makes it include the extension, looking for
the headers under /foo

--without-sqlite3=no does not include it.

IOW: the option should be called --with-sqlite3, not --without-sqlite3







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



#51008 [Opn->Fbk]: Zend/tests/bug45877.phpt fails

2010-02-12 Thread jani
 ID:   51008
 Updated by:   j...@php.net
 Reported By:  geissert at debian dot org
-Status:   Open
+Status:   Feedback
-Bug Type: Unknown/Other Function
+Bug Type: *General Issues
 Operating System: debian sid
 PHP Version:  5.3.1
 New Comment:

In what kind of environment does it fail? It works fine for me in both
32bit and 64bit systems. (using latest SVN checkout of course :)


Previous Comments:


[2010-02-11 01:54:21] geissert at debian dot org

Description:

The test fails 

Reproduce code:
---



Expected result:

array(2) {
  [2147483647]=>
  int(1)
  [-2147483648]=>
  int(1)
  ["2147483648"]=>
  int(1)
}


Actual result:
--
array(2) {
  [2147483647]=>
  int(1)
  [-2147483648]=>
  int(1)
}






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



#38805 [Asn]: PDO Truncates Text from SQL Server Text Data Type Field

2010-02-12 Thread sfox
 ID:   38805
 Updated by:   s...@php.net
 Reported By:  gkrajci at arescorporation dot com
 Status:   Assigned
 Bug Type: PDO related
 Operating System: Windows NT PBMA-WB2 5.2 build 37
 PHP Version:  5.1.6
 Assigned To:  sfox
 New Comment:

Those changes are still in SVN. That means the TEXTLIMIT var is being
set to its highest possible value, which in turn means that truncation
shouldn't be an issue now.

$pdo->query('SET TEXTSIZE 30');

should work from PHP 5.2.11 up, it just needs doccing.


Previous Comments:


[2010-02-12 09:05:28] philipp at servicemail24 dot de

This problem is actually fixed in cvs:

http://www.mail-archive.com/php-...@lists.php.net/msg40731.html
http://www.mail-archive.com/php-...@lists.php.net/msg40711.html

Here is the working source code:

http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/

I have no idea why these fixes aren't included in the 5.2 and 5.3
releases!

@sfox can you ensure that pdo_dblib is updated with the release of
5.2.13 and 5.3.2?



[2010-02-11 15:40:43] philipp at servicemail24 dot de

php 5.3.2 dotdeb still suffers from this problem.

does this fix help?

"Possible fix: remove "case SQLTEXT" from
ext/pdo_dblib/dblib_stmt.c:execute and let it fall though to default."



[2010-01-22 22:51:02] ssufficool at gmail dot com

I imagine the problem is that PDO DBLIB just mem-copies the first
packet of TEXT without calling dbgettext() to retrieve the remainder.

MSSQL handles TEXT fields using dbconvert() which may call dbgettext()
downstream.

Possible fix: remove "case SQLTEXT" from
ext/pdo_dblib/dblib_stmt.c:execute and let it fall though to default.



[2010-01-10 23:22:50] ka...@php.net

Steph, does this need any additional changes to pdo_mssql/pdo_dblib?
And what exactly should be documented?



[2009-09-02 15:28:50] aballard at gmail dot com

According to the SQL Server documenation, SET TEXTSIZE { number } by
itself is not sufficient. That's why the original mssql library has two
configuration directives: mssql.textlimit and mssql.textsize

Since PDO is configured not to use configuration directives, it would
be nice if the pdo_mssql driver added two driver_options to configure
these values.


A quote from SQL Server Books Online:


Setting SET TEXTSIZE affects the @@TEXTSIZE function.

The DB-Library variable DBTEXTLIMIT also limits the size of text data
returned with a SELECT statement. If DBTEXTLIMIT is set to a smaller
size than TEXTSIZE, only the amount specified by DBTEXTLIMIT is
returned. For more information, see "Programming DB-Library for C" in
SQL Server Books Online.

The SQL Server ODBC driver and Microsoft OLE DB Provider for SQL Server
automatically set TEXTSIZE to 2147483647 when connecting.

The setting of set TEXTSIZE is set at execute or run time and not at
parse time.



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

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



#51014 [Opn->Csd]: ext/xmlrpc/tests/bug18916.phpt is missing the SKIPIF section

2010-02-12 Thread jani
 ID:   51014
 Updated by:   j...@php.net
 Reported By:  jess at zend dot com
-Status:   Open
+Status:   Closed
 Bug Type: XMLRPC-EPI related
 Operating System: *
 PHP Version:  5.3.1
 New Comment:

This bug has been fixed in SVN.

Snapshots of the sources are packaged every three hours; this change
will be in the next snapshot. You can grab the snapshot at
http://snaps.php.net/.
 
Thank you for the report, and for helping us make PHP better.




Previous Comments:


[2010-02-12 16:46:12] j...@php.net

There is no such OS called 'ALL'.



[2010-02-11 12:50:46] jess at zend dot com

Same goes for:
ext/xmlrpc/tests/bug44996.phpt
ext/xmlrpc/tests/bug45226.phpt
ext/xmlrpc/tests/bug4.phpt
ext/xmlrpc/tests/bug45556.phpt
ext/xmlrpc/tests/bug47818.phpt



[2010-02-11 12:45:13] jess at zend dot com

Description:

Summary pretty much says it all.

Here's a patch:
--- php-5.3.1/ext/xmlrpc/tests/bug18916.phpt2008-09-10
03:07:45.0 +0300
+++ php-5.3.1/ext/xmlrpc/tests/bug18916.phpt.mod2010-02-11
17:39:52.0 +0200
@@ -1,5 +1,10 @@
 --TEST--
 Bug #18916 (xmlrpc_set_type() not working)
+--SKIPIF--
+
+
 --INI--
 date.timezone="America/Sao_Paulo"
 --FILE--







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



#51014 [Opn]: ext/xmlrpc/tests/bug18916.phpt is missing the SKIPIF section

2010-02-12 Thread jani
 ID:   51014
 Updated by:   j...@php.net
 Reported By:  jess at zend dot com
 Status:   Open
 Bug Type: XMLRPC-EPI related
-Operating System: ALL
+Operating System: *
 PHP Version:  5.3.1
 New Comment:

There is no such OS called 'ALL'.


Previous Comments:


[2010-02-11 12:50:46] jess at zend dot com

Same goes for:
ext/xmlrpc/tests/bug44996.phpt
ext/xmlrpc/tests/bug45226.phpt
ext/xmlrpc/tests/bug4.phpt
ext/xmlrpc/tests/bug45556.phpt
ext/xmlrpc/tests/bug47818.phpt



[2010-02-11 12:45:13] jess at zend dot com

Description:

Summary pretty much says it all.

Here's a patch:
--- php-5.3.1/ext/xmlrpc/tests/bug18916.phpt2008-09-10
03:07:45.0 +0300
+++ php-5.3.1/ext/xmlrpc/tests/bug18916.phpt.mod2010-02-11
17:39:52.0 +0200
@@ -1,5 +1,10 @@
 --TEST--
 Bug #18916 (xmlrpc_set_type() not working)
+--SKIPIF--
+
+
 --INI--
 date.timezone="America/Sao_Paulo"
 --FILE--







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



#50969 [Bgs]: operator overloading for classes

2010-02-12 Thread rasmus
 ID:   50969
 Updated by:   ras...@php.net
 Reported By:  sylvain at abstraction dot fr
 Status:   Bogus
 Bug Type: Feature/Change Request
 Operating System: all
 PHP Version:  5.3.2RC1
 New Comment:

Sorry, this will never happen.  Basic operators need to be 
deterministic in PHP.  You can disagree if you like, but that isn't 
going to change anything.


Previous Comments:


[2010-02-12 13:28:30] sylvain at abstraction dot fr

Well it is maybe implemented but it's beta and has not been updated 
for over 3 years. It is not usable in a 
production environment.

Regarding your point that it is not readable, objects implementing 
Iterator can be used with the foreach 
statement (which is an overloading) and for objects with multiples 
propertiesn you don't know what is done 
unless you read the code.

So, I don't see why we could not have overator overloading already 
having foreach overloading.

Things can get "funny" with overloading, yes, but that's not a reason 
to not implement it. You can't state you 
won't allow something because some people will not use it correctly, 
in that case, you allow nothing and you 
don't implement a dynamically weak typed language. It is up to the 
developer to secure its implementation. You 
must have a little faith in him.

Here an exemple of what I have in mind based on the Iterator model :

interface OperatorOverloading
{
public function __add($object);
public function __substract($object);
public function __multiply($object);
public function __divide($object);
public function __increment();
public function __decrement();
}

class foo implements OperatorOverloading
{
private $anynumber = 0;

public function __add($object)
{
if (!$object instanceof __CLASS__)
{
throw new Exception('Come on !!!');
}

$return = new foo();
$return->anynumber = $this->anynumber + $object-
>anynumber;

return $return;
}

public function __increment()
{
$this->anynumber++;
}

public function __decrement()
{
$this->anynumber--;
}

public function __substract($object)
{
throw new Exception('not implemented');
}

public function __divide($object)
{
throw new Exception('not implemented');
}

public function __multiply($object)
{
throw new Exception('not implemented');
}
}

Regards.



[2010-02-08 23:54:47] johan...@php.net

Well it is implemented, as you can see when following the link, I
myself once created a patch to make it a bit nicer in syntax but it will
never be implemented (as far as never goes)

And well the issue, in the most simple form, is something like this:

function foo() {
return bar() + baz();
}

In today's world during are view you can say "this will return a
numeric value"with operator overloading you can say "this will return
something or maybe fail"

Becomes especially "funny" with

return bar() + 4;

Sure there's convention and comments and things but that won't help and
you can always do

   return bar()->add(baz());

or

   return someclass::add(bar(), baz());

which makes the intention clear. Yes $a + $b + $c + $d might be bit
nicer to read than the long form - but only as long as you know what
types you have ...



[2010-02-08 23:15:17] sylvain at abstraction dot fr

I'm not particularly aware of operator overloading in other language
but I don't see why it would be less readable in PHP than in any other
language as the only way to know what is happening is to read the code
of the method overloading the operator.

Anyhow, do I have to take as official PHP Team position that you won't
implement it ?



[2010-02-08 22:59:25] johan...@php.net

Operator overloading in a dynamically weak typed language is bad as
reading code gives no information what's happening. If you really want
it go to http://pecl.php.net/operator maybe that still works.



[2010-02-08 22:49:23] sylvain at abstraction dot fr

Description:

I would like to know what is the current PHP team position about
operator overloading in PHP for classes.

Operator overloading has been stated Bogus in
http://bugs.php.net/bug.php?id=9331 but it was more than two years ago.

I think it would be nice to have a discussion about that topic. If you
recently had one I would be

#51015 [Opn->Bgs]: Array keys can not be used to get values

2010-02-12 Thread jani
 ID:   51015
 Updated by:   j...@php.net
 Reported By:  nat at search dot ch
-Status:   Open
+Status:   Bogus
 Bug Type: *General Issues
 Operating System: Linux #1 SMP 2009-08-15 17:53:59
 PHP Version:  5.3.1
 New Comment:

RTFM:

http://php.net/array#language.types.array.casting

"If an object is converted to an array, the result is an array whose
elements are the object's properties. The keys are the member variable
names, with a few notable exceptions: integer properties are
unaccessible.."

And you could also access those directly without casting anyway, like
this:

var_dump($model->choices->{1});





Previous Comments:


[2010-02-11 13:57:10] nat at search dot ch

Description:

In an associative array with number as text keys, the keys can not be
used to get the values. "Foreach" works.

  var_dump($choices);  
// array(2) { ["1"]=>  array(2) { [0]=>  string(1) "0" [1]=>  string(1)
"1" } ["0"]=>  array(2) { [0]=>  string(1) "0" [1]=>  string(1) "1" } }

  var_dump($choices['1']); // NULL
  var_dump($choices[1]);   // NULL
  var_dump($choices["1"]); // NULL
  var_dump($choices->{1}); // NULL
  var_dump($choices->{'1'});//NULL
  var_dump($choices['0']);  //NULL
  var_dump($choices[0]);//NULL

 foreach ($choices as $k => $v) {
var_dump($k, $v);
  }

// string(1) "1" array(2) { [0]=> string(1) "0" [1]=> string(1) "1" }
// string(1) "0" array(2) { [0]=> string(1) "0" [1]=> string(1) "1" }


Reproduce code:
---
$db_data_model='{"events":{"1":"film","0":"avatar"},"times":{"0":"2010-10-09
08:00","2":"2010-10-09
11:00","3":"2010-09-09"},"choices":{"1":["0","1"],"0":["0","1"]}}';
$model = json_decode($db_data_model);
$choices = (array)$model->choices;
var_dump($choices);
var_dump($choices['1']); // NULL
var_dump($choices[1]);   // NULL
var_dump($choices->{1}); // NULL
var_dump($choices->{'1'});//NULL

foreach ($choices as $k => $v) {
var_dump($k, $v);
}



Expected result:

var_dump($choices['1']);

// array(2) { [0]=> string(1) "0" [1]=> string(1) "1" }

var_dump($choices['0']);

// array(2) { [0]=> string(1) "0" [1]=> string(1) "1" }

Actual result:
--
var_dump($choices['1']);

// NULL

var_dump($choices['0']);

// NULL





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



#50915 [NoF->Opn]: ldap extension with Solaris libldap patched for ldap urls

2010-02-12 Thread strube at physik3 dot gwdg dot de
 ID:   50915
 User updated by:  strube at physik3 dot gwdg dot de
 Reported By:  strube at physik3 dot gwdg dot de
-Status:   No Feedback
+Status:   Open
 Bug Type: LDAP related
 Operating System: Solaris 10
 PHP Version:  5.2.12
 New Comment:

> No feedback was provided for this bug for over a week
I have simply been waiting for a reply to my question from 3 Feb 9:13am
UTC. It may seem trivial to you, but I am not sure what to do. Must I
set "Version" to 5.3.1? Can the patch not be uploaded but only a link
given to a file on our local webserver (which will not exist forever)?
(BTW, my password has not been working. I got it sent to me but it was
changed - definitely not by me!)


Previous Comments:


[2010-02-10 01:00:00] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2010-02-03 09:13:01] strube at physik3 dot gwdg dot de

>Please provide patches (links) against PHP_5_3 and trunk.
How must I proceed to do so?



[2010-02-02 17:14:49] paj...@php.net

hi,

Please provide patches (links) against PHP_5_3 and trunk.

Cheers,



[2010-02-02 17:08:00] strube at physik3 dot gwdg dot de

Description:

The PHP extension "ldap" can be build with the native Solaris 10
libldap and works well, except that it does not understand URL format
(ldap://host, ldaps://host). I made a patch for this, based on testing
for _SOLARIS_SDK (defined in /usr/include/ldap.h), which might also work
for other NSLDAP variants. How can I upload this?
(The line numbers seem not to have changed at least from 5.2.10 to
5.3.1.)






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



#51017 [Opn->Bgs]: mail() is sending emails it shouldn't be

2010-02-12 Thread jani
 ID:   51017
 Updated by:   j...@php.net
 Reported By:  son9ne at gmail dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Mail related
 Operating System: Mac OSx
 PHP Version:  5.2.12
 New Comment:

Please consult your local sendmail (or whatever mailer you might be
using) consultant to fix your setup. There's nothing wrong with mail(),
just in your configuration. (no, I don't know what is wrong, mail()
works fine in properly configured environment)


Previous Comments:


[2010-02-11 14:40:53] son9ne at gmail dot com

Description:

I have been working on a simple cron system. I have had no issue with
it up until yesterday. I am not 100% sure how to duplicate this since I
am stuck with this issue and cannot get stop it...

The problem that is happening is when calling mail() for only 1 test
email, it sends over 200 messages with a totally different subject and
message... It's like the emails are cached or something, not my area of
expertise.

I am reporting this to make note of the issue, I doubt I am the only
one having it.

This information may be helpful also. At some point, while still
developing the script, the script did send run though a loop where it
would have sent out over 1,000 emails (all addressed to me). Could these
emails somehow be stuck in the system? I am not that savvy when it comes
to these things... These extra emails are being sent when I am using any
script now that uses the mail function. Thus mail is absolutely useless
at this point for me and has me at a stand still for this script. I have
even tried creating a new file and only having the mail function with a
test message to me and it does the exact same thing. Every script on my
system does this now. 

Reproduce code:
---
Like I have said, I am not aware of how to duplicate what triggered
this to happen; but for me, just calling 

mail('m...@email.com' 'Test subject', 'test message', 'From:
m...@email.com', '-f m...@email.com');

Will send out 100-200 emails to me with a message of an email I was
testing yesterday.


Expected result:

I'd expect to see a single email with the proper subject and content.

Actual result:
--
I do receive the test email but I am also receiving between 100-200
emails of a previous email. Makes me wonder who is getting who's
emails...





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



#51019 [Opn->Bgs]: Problems ldap_add when CN includes forward slash (/)

2010-02-12 Thread jani
 ID:   51019
 Updated by:   j...@php.net
 Reported By:  bruce dot bahlmann at lsiowa dot org
-Status:   Open
+Status:   Bogus
 Bug Type: LDAP related
 Operating System: Windows Vista Business
 PHP Version:  5.2.12
 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-02-11 15:55:51] bruce dot bahlmann at lsiowa dot org

Description:

There seems to be an issue with ldap_add when the cn and corresponding
dn, include a forward slash (/). NOTE, ldap in this case is an active
directory (AD) server. Ldap_add works fine when the cn doesn't include a
forward slash, however, when the text does include it, I cannot get the
ldap_add to work.

I've tried escaping the characters (using backslash) with no success.
I've also tried equivalent characters, but same result - the ldap add
doesn't run.

Interestingly, if one uses LDAP explorer, the entries which have
forward slashes actually show a backward slash before the forward slash.
If I use those tools, I can manually add ldap entries with a forward
slash, just can't do it with php ldap library. I've attached the
ldap_add calling script which provides a wrapper for creating a group on
the ldap server.

Reproduce code:
---
---
>From manual page: function.ldap-add#Parameters
---
function ldapcreateGroup($hash, $dn) {

// Maintain handle on LDAP connection to limit unnecessary ldapOpen
if (!isset($GLOBALS["static_ad"])) {
@ldapOpen();
}   

// Add these fields to ensure proper group be added
$hash['objectClass'][0] = "top";
$hash['objectClass'][1] ="group";
$hash['groupType']=(int)'-2147483646';
$hash['objectcategory'] = 'CN=Group,CN=Schema,CN=Configuration,'.sdn;
$hash["sAMAccountName"] = $hash['cn'];
unset($hash['distinguishedname']);

#print_r($hash);

@ldap_add($GLOBALS["static_ad"],$dn,$hash);

if(@ldap_error($GLOBALS["static_ad"]) == "Success") {
return 1;
} else {
return 0;
}
}

Expected result:

Short of not using forward slashes in the cn, which would take some
time to change in all the various entries in AD, is there some possible
way to get ldap_add to add these?

Or, is there some special preparations required to perform on the cn
field that would allow me to use conventional ldap_add to correctly
insert this entry?

Actual result:
--
none





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



#51022 [Opn->Fbk]: getservbyname_basic.phpt has incorrect description and misses a skip case

2010-02-12 Thread jani
 ID:   51022
 Updated by:   j...@php.net
 Reported By:  geissert at debian dot org
-Status:   Open
+Status:   Feedback
 Bug Type: Network related
 Operating System: debian sid
 PHP Version:  5.3.1
 New Comment:

Why would you not have /etc/services and how is the description wrong?
(patches are welcome..)


Previous Comments:


[2010-02-11 21:29:55] geissert at debian dot org

Description:

The description of
ext/standard/tests/general_functions/getservbyname_basic.phpt is
incorrect, as that's not really what the test is about.
Additionally, a SKIP section should be added to skip the test if
/etc/services does not exist.







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



#51024 [Opn->Bgs]: segmentation fault when concatenating very large strings on Redhat x86

2010-02-12 Thread jani
 ID:   51024
 Updated by:   j...@php.net
 Reported By:  mikerudra at yahoo dot com
-Status:   Open
+Status:   Bogus
 Bug Type: Scripting Engine problem
 Operating System: Redhat EL
 PHP Version:  5.2SVN-2010-02-12 (snap)
 New Comment:

You're also getting a warning:

PHP Warning:  str_repeat(): Second argument has to be greater than or
equal to 0

This is not crashing, segfaulting or anything like that.




Previous Comments:


[2010-02-12 01:20:47] mikerudra at yahoo dot com

Description:

Hi guys, 
I checked this bug report
http://bugs.php.net/bug.php?id=50207
and I updated to a release version from today.
The bug is still there as you can see here

http://nats.hotladies.com/nfo.php


Please tell me what is to be done, I need to install NATS and they do
not accept 5.3, I need the 5.2 version, please help.
Thanks

Reproduce code:
---
$s = str_repeat('A', pow(2,31));
$s .= 'B'; // fails with segfault
printf("strlen: %u last-char: %c", strlen($s), $s[pow(2,31)]);



Expected result:

Donno, should just work?! Is used by NATS and I got an error working
with ioncube encoded source code...

Actual result:
--
Notice: Uninitialized string offset: -2147483648 in
/var/www/vhosts/nats.hotladies.com/nats/www/nfo.php on line 7
strlen: 1 last-char: � 





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



#51026 [Opn->Fbk]: ssl not working

2010-02-12 Thread jani
 ID:   51026
 Updated by:   j...@php.net
 Reported By:  fuxa_kos at unihost dot cz
-Status:   Open
+Status:   Feedback
 Bug Type: MySQLi related
 Operating System: Linux
 PHP Version:  5.3.1
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2010-02-12 13:02:55] fuxa_kos at unihost dot cz

Description:

ssl connection not working, same code with 5.2.12 working well.
With reference to bug 49234, I have support [33] => ssl_set.

mysql client working well too.
mysql ... --ssl-ca=cert/mysql-cacert.pem
--ssl-cert=cert/client-cert.pem --ssl-key=cert/client-key.pem
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 116395
Server version: 5.0.90-community-log MySQL Community Edition (GPL)
mysql> SHOW STATUS LIKE 'Ssl_cipher';
+---++
| Variable_name | Value  |
+---++
| Ssl_cipher| DHE-RSA-AES256-SHA |
+---++
1 row in set (0.00 sec)

from phpinfo
mysqli

MysqlI Support => enabled
Client API library version => 5.1.42
Active Persistent Links => 0
Inactive Persistent Links => 0
Active Links => 0
Client API header version => 5.1.42
MYSQLI_SOCKET => /var/lib/mysql/mysql.sock

Directive => Local Value => Master Value
mysqli.allow_local_infile => Off => Off
mysqli.allow_persistent => On => On
mysqli.default_host => no value => no value
mysqli.default_port => 3306 => 3306
mysqli.default_pw => no value => no value
mysqli.default_socket => no value => no value
mysqli.default_user => no value => no value
mysqli.max_links => Unlimited => Unlimited
mysqli.max_persistent => Unlimited => Unlimited
mysqli.reconnect => Off => Off

Client is Mysql 5.1 and server is Mysql 5.0. But same for 5.0 Mysql 
client. In case PHP 5.2 Mysql client is 5.0.

Reproduce code:
---
ssl_set('./cert/client-key.pem', './cert/client-cert.pem',
'./cert/mysql-cacert.pem', null, null);
$mysqli->real_connect('removed', '', '', '');
if ($r = $mysqli->query("SHOW STATUS LIKE 'Ssl_cipher'")) {
var_dump($r->fetch_row());
}
echo $mysqli->error."\n";
echo $mysqli->errno."\n";

Expected result:

something like this for Ssl_cipher
array(2) {
  [0]=>
  string(10) "Ssl_cipher"
  [1]=>
  string(18) "DHE-RSA-AES256-SHA"
}

and no errors.

Actual result:
--
Warning: mysqli::ssl_set(): invalid object or resource mysqli

with MYSQLI_CLIENT_SSL
Can't connect to MySQL server on 'removed' (113)
errno = 2003
 
without MYSQLI_CLIENT_SSL
Warning: mysqli::real_connect(): (28000/1045): Access denied for 
user 'removed' (using password: YES)
errno = 1045

ssl_set() in this case returns NULL, not true as doc says.





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



#51023 [Opn->Fbk]: ext/filter/tests/046.phpt fails, does not detect int overflow

2010-02-12 Thread jani
 ID:  51023
 Updated by:  j...@php.net
 Reported By: geissert at debian dot org
-Status:  Open
+Status:  Feedback
 Bug Type:Filter related
 PHP Version: 5.3.1
 New Comment:

Please try using this snapshot:

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

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




Previous Comments:


[2010-02-11 23:31:02] geissert at debian dot org

Description:

The filter fails to detect an integer overflow and passes the
FILTER_VALIDATE_INT test. The problem is caused because
php_filter_parse_int uses a long to detect the overflow, which of course
doesn't have the same size of an integer.

This can be fixed by making ctx_value an integer in both
php_filter_parse_int and php_filter_int (and for correctness, not
setting Z_TYPE_P(value) to IS_LONG).


Reproduce code:
---
// the current test:
$s = sprintf("%d", PHP_INT_MAX);
var_dump(is_long(filter_var($s, FILTER_VALIDATE_INT)));

$s = sprintf("%.0f", PHP_INT_MAX+1);
var_dump(filter_var($s, FILTER_VALIDATE_INT));

$s = sprintf("%d", -PHP_INT_MAX);
var_dump(is_long(filter_var($s, FILTER_VALIDATE_INT)));

Expected result:

bool(true)
bool(false)
bool(true)


Actual result:
--
bool(true)
int(-2147483648)
bool(true)





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



#51025 [Opn->Bgs]: Dynamic loading disabled when cross compiling

2010-02-12 Thread jani
 ID:   51025
 Updated by:   j...@php.net
 Reported By:  ncoesel at dealogic dot nl
-Status:   Open
+Status:   Bogus
-Bug Type: *Compile Issues
+Bug Type: Compile Failure
 Operating System: Linux
 PHP Version:  5.2.12
 New Comment:

Cross compiling is not and will not be supported out-of-box. Ever.
If you need to cross compile you better know what you're doing and
hence you're able to modify the Makefile and php_config.h files
yourself.


Previous Comments:


[2010-02-12 09:56:28] ncoesel at dealogic dot nl

Description:

For some reason dynamic loading is disabled when cross compiling
(version 5.2.6 -sorry can't upgrade-) altough libdl is present and
properly detected. Or is this some automake/autoconf bug? When I modify
configure to skip the cross compiling test, dynamic loading works just
fine on a mipsel (MIPS little endian) platform.






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



#47948 [Com]: call_user_func_array() with autoload causes crash

2010-02-12 Thread janssens dot cyril at gmail dot com
 ID:   47948
 Comment by:   janssens dot cyril at gmail dot com
 Reported By:  ehassler at synapsestudios dot com
 Status:   No Feedback
 Bug Type: Reproducible crash
 Operating System: *
 PHP Version:  5.2.9
 New Comment:

Same problem on Debian 5 32bit + php 5.2.6 when using recursive
call_user_func_array function.

The workaround is to use eval statement:

$object = 'foo';
$method = 'bar';
$args = array();//some arguments
$i=0;
$strArg='';
foreach ($args as $arg){
$varname = 'arg'.$i;
$$varname = $arg;
$strArg .= '$'.$varname.',';
$i++;
}
$strArg = substr($strArg,0,-1);
$cmd = '$_return = '.$object.'::'.$method.'('.$strArg.');';
eval($cmd);

//Enjoy :-)
return $_return;




Regards,

Cyril


Previous Comments:


[2010-01-11 01:00:00] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2010-01-08 16:27:47] muqker at muqker dot com

I didn't know about Edit Submission. However, I did not open this bug,

I just had the same problem and tried to provide a script to 
reproduce. Should I use that anyway?

Yes, the crash is there. I am getting:

[Fri Jan 08 17:55:49 2010] [notice] child pid 3534 exit signal 
Segmentation fault (11)

in apache2's error log and the browser reports that it receives "Error

324 (net::ERR_EMPTY_RESPONSE): Unknown error."

php -n index.php ends with "Segmentation Fault".

If I include explicitly the class that otherwise autoload tries to 
load, or if I do not use call_user_func_array, but a normal call, then

the crash is gone.

Some system info:
PHP Version 5.2.6-3ubuntu4.2
Apache Version  Apache/2.2.11 (Ubuntu) DAV/2 SVN/1.5.4 PHP/5.2.6-
3ubuntu4.2 with Suhosin-Patch
Apache API Version  20051115
Loaded Modules  core mod_log_config mod_logio prefork http_core mod_so 
mod_alias mod_auth_basic mod_authn_file mod_authz_default 
mod_authz_groupfile mod_authz_host mod_authz_user mod_autoindex 
mod_cgi mod_dav mod_dav_fs mod_dav_svn mod_authz_svn mod_deflate 
mod_dir mod_env mod_mime mod_negotiation mod_php5 mod_rewrite 
mod_setenvif mod_status
Linux dufus 2.6.28-16-generic #55-Ubuntu SMP Tue Oct 20 19:48:24 UTC 
2009 i686
GNU C Library stable release version 2.9, by Roland McGrath et al.

Let me know if I can provide any other info.



[2010-01-03 20:54:56] johan...@php.net

When editing you have to use the "Edit Submission" tab to re-open it.

Are you sure the script you provided is correct - it works for me, as
far as I can tell, on 5.2 and 5.3 while there is a warning for a missing
parameter:

$ php -n index.php 
array(7) {
  [0]=>
  array(7) {
["file"]=>
string(47) "/tmp/test47948/muqker/index.php"
["line"]=>
int(41)
["function"]=>
string(1) "f"
["class"]=>
string(1) "A"
["object"]=>
object(A)#2 (0) {
}
["type"]=>
string(2) "->"
["args"]=>
array(0) {
}
  }
  [1]=>
  array(7) {
["file"]=>
string(47) "/tmp/test47948/muqker/index.php"
["line"]=>
int(45)
["function"]=>
string(1) "g"
["class"]=>
string(1) "A"
["object"]=>
object(A)#2 (0) {
}
["type"]=>
string(2) "->"
["args"]=>
array(0) {
}
  }
  [2]=>
  array(7) {
["file"]=>
string(47) "/tmp/test47948/muqker/index.php"
["line"]=>
int(15)
["function"]=>
string(1) "h"
["class"]=>
string(1) "A"
["object"]=>
object(A)#2 (0) {
}
["type"]=>
string(2) "->"
["args"]=>
array(0) {
}
  }
  [3]=>
  array(7) {
["file"]=>
string(47) "/tmp/test47948/muqker/index.php"
["line"]=>
int(19)
["function"]=>
string(2) "zz"
["class"]=>
string(10) "Controller"
["object"]=>
object(Controller)#1 (0) {
}
["type"]=>
string(2) "->"
["args"]=>
array(0) {
}
  }
  [4]=>
  array(7) {
["file"]=>
string(47) "/tmp/test47948/muqker/index.php"
["line"]=>
int(23)
["function"]=>
string(10) "executeNew"
["class"]=>
string(10) "Controller"
["object"]=>
object(Controller)#1 (0) {
}
["type"]=>
string(2) "->"
["args"]=>
array(1) {
  [0]=>
  &NULL
}
  }
  [5]=>
  array(7) {
["file"]=>
string(47) "/tmp/test47948/muqker/index.php"
["line"]=>
int(59)
["function"]=>
string(13) "executeClient"
["class"]=>
string(10) "Controller"
["object"]=>
object(Controller)#1 (0) {
}
["type"]=>
string(2) "->"
["args"]=>
array(1) {
  [0]=>
  &NULL
}
  }
  [6]=>
  array(4) {
["file"]=>
string(47) "/tmp/

#50953 [Bgs]: fsockopen will not work on 'localhost'

2010-02-12 Thread tony at marston-home dot demon dot co dot uk
 ID:   50953
 User updated by:  tony at marston-home dot demon dot co dot uk
 Reported By:  tony at marston-home dot demon dot co dot uk
 Status:   Bogus
 Bug Type: Sockets related
 Operating System: Windows XP
 PHP Version:  5.2.12
 New Comment:

If IPv6 support is enabled in the operating system it does NOT mean
that only IPv6 addresses are allowed, it means that both IPv5 and IPv6
addresses are supported.

All of my web browsers (IE, Firefox, Opera, Safari) have no problem in
translating 'localhost' to '127.0.0.1'.

The PHP gethostbyname() function has no problem in translating
'localhost' to '127.0.0.1'.

The PHP cURL extension has no problem in translating 'localhost' to
'127.0.0.1'.

fsockopen() when running in PHP 5.3.0 has no problem in translating
'localhost' to '127.0.0.1'.

So why does fsockopen() in php 5.2.12 have a problem?


Previous Comments:


[2010-02-10 11:27:25] tony at marston-home dot demon dot co dot uk

This has got nothing to do with IPV6 addresses as my hosts file does
not contain anf IPV6 addresses. All it has is as follows:

127.0.0.1   localhost

Every other piece of software on my PC uses 'loalhost' without a
problem, so should fsockopen in PHP. Curl can manage it, so why not
fsockopen.

I have the same setup on another PC which runs Windows XP with IPV6
support and PHP 5.3.0, and it does not have a problem with 'localhost',
so this is a genuine bug in 5.2

Do not keep telling me that you have already addressed this issue in
other posts because you have not. You nhave suggested removing any IPV6
entries from the hosts file, which I have done, but this does not fix
the problem.

If gethostbyname() can work with 'localhost' then why can't
fsockopen()?



[2010-02-10 11:06:08] paj...@php.net

It works just fine here using localhost and ipv4.

You are clearly experiencing the IPv6 problem described in a good dozen
bugs here (with solutions).

I'm sorry if it is not acceptable but we can't do anything about that,
see the other reports for a complete and detailed explanation.



[2010-02-10 10:57:11] tony at marston-home dot demon dot co dot uk

THIS IS NOT BOGUS, IT IS A GENUINE BUG!!!

If print_r(gethostbynamel('localhost'));  produces the following:

Array
(
[0] => 127.0.0.1
)

then why can't fsockopen connect to 'localhost'? It is a valid name
which is recognised by every other piece of software on my computer, so
there is no good reason why fsockopen should have a problem with it.

I have another PC which runs 5.3.0 where fsockopen does not have a
problem with 'localhost', therefore there is a bug in 5.2



[2010-02-10 10:18:16] paj...@php.net

Already explained why it can't and won't be fixed in 5.2, neither in
5.3. Use the IP then instead of the hostname. Bogus (duplicated, not
really a bug per se but a feature,etc.)



[2010-02-10 08:17:49] carsten_sttgt at gmx dot de

> Did you install IPv6 support for XP?

Yes.


> Comment out the IPv6 entries for localhost

Of course not! (PHP is not the center of the universe and i need a
working IPv6)


> (see the other bogus reports for detailed explanations

Don't you think it's better to fix the bug in the streams code?
(Already explained in an other bug report about mysqlnd)


BTW (regarding the above quirk):
- for XP it's also a good idea to verify that there is a entry for IPv4
in the HOSTS file (or just deinstall IPv6) 
- and that's not working for e.g. Windows 7.


Regards,
Carsten



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

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



#50578 [Com]: incorrect shebang in phar.phar

2010-02-12 Thread Fedora at famillecollet dot com
 ID:   50578
 Comment by:   Fedora at famillecollet dot com
 Reported By:  Fedora at FamilleCollet dot com
 Status:   Assigned
 Bug Type: PHAR related
 Operating System: Linux (Fedora 12)
 PHP Version:  5.3.2RC1
 Assigned To:  cellog
 New Comment:

Same issue with PHP 5.3.2RC2


Previous Comments:


[2009-12-26 12:28:34] Fedora at FamilleCollet dot com

Trivial which fix the issue :
http://remi.fedorapeople.org/php-5.3.2-phar.patch



[2009-12-26 12:26:46] Fedora at FamilleCollet dot com

Description:

default PHP_PHARCMD_BANG is PHP_EXCUTABLE which is relative to
top_builddir.

This result to a php.phar which include a bad path to php.

Until PHP 5.3.1, PHP_EXCUTABLE was not set (by default) on Makefile, so
all works fine

With 5.3.2RC1, PHP_EXCUTABLE is set to
$(top_builddir)/$(SAPI_CLI_PATH)








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



#47418 [Fbk]: number_format misbehaving with some values

2010-02-12 Thread pajoye
 ID:   47418
 Updated by:   paj...@php.net
 Reported By:  cu19 at gmx dot de
 Status:   Feedback
 Bug Type: *Math Functions
 Operating System: Win7
 PHP Version:  5.3.1
 New Comment:

It could be an encoding issue then (before it gets formatted). Can you
zip the script and the excel file you use and post a link to it here? Or
drop me a mail.


Previous Comments:


[2010-02-12 14:15:30] tdietsche at comcast dot net

I am not sure what you mean by "isolate the value which causes problems
and pass it directly to number_format". If I just assign 19 to a
variable (either as a string or as a number) and do this, it works fine.
It is only when it comes from a result row value of a number-formatted
excel spreadsheet cell that it shows the problem, for me.

You could try a much simpler spreadsheet but I gave all the details of
the one I am using that shows the problem, in case for some reason the
spreadsheet details are related somehow (probably not though).

I don't have time to install a new version of php right now, maybe
later. I have already spent more time on this than I can afford.

One other note, I see in playing around I changed some variable names
in one function, it should really read:

function FmtAmt($amt) {
  // another workaround for the total
  if ((string)$amt == '18.:') $amt = '19';  
  $cred = '';
  if ($amt < 0) {
$amt  = 0 - $amt;
$cred = 'CR';
  }
  // uncomment this and comment out next line to see bug
  // $ret = number_format($amt, 2) . $cred;  
  $ret = stupid_php($amt) . $cred;
  return $ret;
}



[2010-02-12 14:07:58] paj...@php.net

Can you try to isolate the value which causes problems and pass it
directly to number_format? That will be easier to debug and fix.

Can you aslo try using 5.3.2RC2 (VC9 builds if possible, via CLI or
using apachelounge.com's apache).



[2010-02-12 13:32:28] tdietsche at comcast dot net

In case it might help, here is my php config (on WinXP SP3):


  PHP Version 5.3.1


System  Windows NT DIY2004 5.1 build 2600 (Windows XP Professional
Service Pack 3) i586
Build Date  Nov 19 2009 10:16:45
CompilerMSVC6 (Visual C++ 6.0)
Architecturex86
Configure Command   cscript /nologo configure.js
"--enable-snapshot-build" "--disable-isapi" "--enable-debug-pack"
"--disable-isapi"
"--with-pdo-oci=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8-11g=D:\php-sdk\oracle\instantclient11\sdk,shared"
"--enable-object-out-dir=../obj/"
Server API  Apache 2.0 Handler
Virtual Directory Support   enabled
Configuration File (php.ini) Path   C:\WINDOWS
Loaded Configuration File   C:\PHP\php.ini
Scan this dir for additional .ini files (none)
Additional .ini files parsed(none)
PHP API 20090626
PHP Extension   20090626
Zend Extension  220090626
Zend Extension BuildAPI220090626,TS,VC6
PHP Extension Build API20090626,TS,VC6
Debug Build no
Thread Safety   enabled
Zend Memory Manager enabled
Zend Multibyte Support  disabled
IPv6 Supportenabled
Registered PHP Streams  php, file, glob, data, http, ftp, zip,
compress.zlib, compress.bzip2, https, ftps, phar
Registered Stream Socket Transports tcp, udp, ssl, sslv3, sslv2, tls
Registered Stream Filters   convert.iconv.*, string.rot13,
string.toupper, string.tolower, string.strip_tags, convert.*,
consumed,
dechunk, zlib.*, bzip2.*



[2010-02-12 13:19:29] tdietsche at comcast dot net

/* 
set up an Excel 97-2003 spreadsheet with a worksheet 'Nov'
and the row headers below on row 3
then add a row 14 with "John Smith" in Tenant, "11" in Lot, and "19" in
Late Fee.
Late fee should be number format with 2 decimals and comma thousands
separator format.
Create an odbc system DSN called "rent_2009" linked to it.
Then run this script against it, I have stripped it down but I think it
will show the problem.
note this will NOT show the problem if you just supply variable values
directly, it has to come
from excel and has something to do with the (string) casting of values
that excel thinks are numbers.
somehow the float and string are getting goofed up. Even when I fixed
the value, the total it was
being added to still had the problem until I hardwired a second test on
"18.:0" to fix that. Jeez.

(row headers):
Tenant
Lot
Prev Bal
Rent
LP Gas
Taxes
Garbage
Elec CR
Mowing
Late Fee
Misc
Deposit
New Bal
Check
Cash
Mail
Bal Fwd
Last Mon
This Mon
Change
Factor
Gallons
Rate/Gal
LP Amt
NOTES
Misc Desc

*/
$result= '';
$month_total = 0;
$totals  = array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);

function FmtFieldAmt($tot_num, $field_name) {
  global $result, $month_total, $totals;

#47418 [Com]: number_format misbehaving with some values

2010-02-12 Thread tdietsche at comcast dot net
 ID:   47418
 Comment by:   tdietsche at comcast dot net
 Reported By:  cu19 at gmx dot de
 Status:   Feedback
 Bug Type: *Math Functions
 Operating System: Win7
 PHP Version:  5.3.1
 New Comment:

I am not sure what you mean by "isolate the value which causes problems
and pass it directly to number_format". If I just assign 19 to a
variable (either as a string or as a number) and do this, it works fine.
It is only when it comes from a result row value of a number-formatted
excel spreadsheet cell that it shows the problem, for me.

You could try a much simpler spreadsheet but I gave all the details of
the one I am using that shows the problem, in case for some reason the
spreadsheet details are related somehow (probably not though).

I don't have time to install a new version of php right now, maybe
later. I have already spent more time on this than I can afford.

One other note, I see in playing around I changed some variable names
in one function, it should really read:

function FmtAmt($amt) {
  // another workaround for the total
  if ((string)$amt == '18.:') $amt = '19';  
  $cred = '';
  if ($amt < 0) {
$amt  = 0 - $amt;
$cred = 'CR';
  }
  // uncomment this and comment out next line to see bug
  // $ret = number_format($amt, 2) . $cred;  
  $ret = stupid_php($amt) . $cred;
  return $ret;
}


Previous Comments:


[2010-02-12 14:07:58] paj...@php.net

Can you try to isolate the value which causes problems and pass it
directly to number_format? That will be easier to debug and fix.

Can you aslo try using 5.3.2RC2 (VC9 builds if possible, via CLI or
using apachelounge.com's apache).



[2010-02-12 13:32:28] tdietsche at comcast dot net

In case it might help, here is my php config (on WinXP SP3):


  PHP Version 5.3.1


System  Windows NT DIY2004 5.1 build 2600 (Windows XP Professional
Service Pack 3) i586
Build Date  Nov 19 2009 10:16:45
CompilerMSVC6 (Visual C++ 6.0)
Architecturex86
Configure Command   cscript /nologo configure.js
"--enable-snapshot-build" "--disable-isapi" "--enable-debug-pack"
"--disable-isapi"
"--with-pdo-oci=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8-11g=D:\php-sdk\oracle\instantclient11\sdk,shared"
"--enable-object-out-dir=../obj/"
Server API  Apache 2.0 Handler
Virtual Directory Support   enabled
Configuration File (php.ini) Path   C:\WINDOWS
Loaded Configuration File   C:\PHP\php.ini
Scan this dir for additional .ini files (none)
Additional .ini files parsed(none)
PHP API 20090626
PHP Extension   20090626
Zend Extension  220090626
Zend Extension BuildAPI220090626,TS,VC6
PHP Extension Build API20090626,TS,VC6
Debug Build no
Thread Safety   enabled
Zend Memory Manager enabled
Zend Multibyte Support  disabled
IPv6 Supportenabled
Registered PHP Streams  php, file, glob, data, http, ftp, zip,
compress.zlib, compress.bzip2, https, ftps, phar
Registered Stream Socket Transports tcp, udp, ssl, sslv3, sslv2, tls
Registered Stream Filters   convert.iconv.*, string.rot13,
string.toupper, string.tolower, string.strip_tags, convert.*,
consumed,
dechunk, zlib.*, bzip2.*



[2010-02-12 13:19:29] tdietsche at comcast dot net

/* 
set up an Excel 97-2003 spreadsheet with a worksheet 'Nov'
and the row headers below on row 3
then add a row 14 with "John Smith" in Tenant, "11" in Lot, and "19" in
Late Fee.
Late fee should be number format with 2 decimals and comma thousands
separator format.
Create an odbc system DSN called "rent_2009" linked to it.
Then run this script against it, I have stripped it down but I think it
will show the problem.
note this will NOT show the problem if you just supply variable values
directly, it has to come
from excel and has something to do with the (string) casting of values
that excel thinks are numbers.
somehow the float and string are getting goofed up. Even when I fixed
the value, the total it was
being added to still had the problem until I hardwired a second test on
"18.:0" to fix that. Jeez.

(row headers):
Tenant
Lot
Prev Bal
Rent
LP Gas
Taxes
Garbage
Elec CR
Mowing
Late Fee
Misc
Deposit
New Bal
Check
Cash
Mail
Bal Fwd
Last Mon
This Mon
Change
Factor
Gallons
Rate/Gal
LP Amt
NOTES
Misc Desc

*/
$result= '';
$month_total = 0;
$totals  = array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);

function FmtFieldAmt($tot_num, $field_name) {
  global $result, $month_total, $totals;
  $res = odbc_result($result, $field_name);
  $fld_amt = GetDec($res);
  $fmt_amt = FmtAmt($fld_amt);
  $month_total  += $fmt_amt;
  $totals[$tot_num] += $fmt_amt;
  return $fmt_amt;
}
function GetDec($value) {
  if ($value == null || (string)$value == '')
return 0

#47418 [Opn->Fbk]: number_format misbehaving with some values

2010-02-12 Thread pajoye
 ID:   47418
 Updated by:   paj...@php.net
 Reported By:  cu19 at gmx dot de
-Status:   Open
+Status:   Feedback
 Bug Type: *Math Functions
 Operating System: Win7
 PHP Version:  5.3.1
 New Comment:

Can you try to isolate the value which causes problems and pass it
directly to number_format? That will be easier to debug and fix.

Can you aslo try using 5.3.2RC2 (VC9 builds if possible, via CLI or
using apachelounge.com's apache).


Previous Comments:


[2010-02-12 13:32:28] tdietsche at comcast dot net

In case it might help, here is my php config (on WinXP SP3):


  PHP Version 5.3.1


System  Windows NT DIY2004 5.1 build 2600 (Windows XP Professional
Service Pack 3) i586
Build Date  Nov 19 2009 10:16:45
CompilerMSVC6 (Visual C++ 6.0)
Architecturex86
Configure Command   cscript /nologo configure.js
"--enable-snapshot-build" "--disable-isapi" "--enable-debug-pack"
"--disable-isapi"
"--with-pdo-oci=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8-11g=D:\php-sdk\oracle\instantclient11\sdk,shared"
"--enable-object-out-dir=../obj/"
Server API  Apache 2.0 Handler
Virtual Directory Support   enabled
Configuration File (php.ini) Path   C:\WINDOWS
Loaded Configuration File   C:\PHP\php.ini
Scan this dir for additional .ini files (none)
Additional .ini files parsed(none)
PHP API 20090626
PHP Extension   20090626
Zend Extension  220090626
Zend Extension BuildAPI220090626,TS,VC6
PHP Extension Build API20090626,TS,VC6
Debug Build no
Thread Safety   enabled
Zend Memory Manager enabled
Zend Multibyte Support  disabled
IPv6 Supportenabled
Registered PHP Streams  php, file, glob, data, http, ftp, zip,
compress.zlib, compress.bzip2, https, ftps, phar
Registered Stream Socket Transports tcp, udp, ssl, sslv3, sslv2, tls
Registered Stream Filters   convert.iconv.*, string.rot13,
string.toupper, string.tolower, string.strip_tags, convert.*,
consumed,
dechunk, zlib.*, bzip2.*



[2010-02-12 13:19:29] tdietsche at comcast dot net

/* 
set up an Excel 97-2003 spreadsheet with a worksheet 'Nov'
and the row headers below on row 3
then add a row 14 with "John Smith" in Tenant, "11" in Lot, and "19" in
Late Fee.
Late fee should be number format with 2 decimals and comma thousands
separator format.
Create an odbc system DSN called "rent_2009" linked to it.
Then run this script against it, I have stripped it down but I think it
will show the problem.
note this will NOT show the problem if you just supply variable values
directly, it has to come
from excel and has something to do with the (string) casting of values
that excel thinks are numbers.
somehow the float and string are getting goofed up. Even when I fixed
the value, the total it was
being added to still had the problem until I hardwired a second test on
"18.:0" to fix that. Jeez.

(row headers):
Tenant
Lot
Prev Bal
Rent
LP Gas
Taxes
Garbage
Elec CR
Mowing
Late Fee
Misc
Deposit
New Bal
Check
Cash
Mail
Bal Fwd
Last Mon
This Mon
Change
Factor
Gallons
Rate/Gal
LP Amt
NOTES
Misc Desc

*/
$result= '';
$month_total = 0;
$totals  = array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);

function FmtFieldAmt($tot_num, $field_name) {
  global $result, $month_total, $totals;
  $res = odbc_result($result, $field_name);
  $fld_amt = GetDec($res);
  $fmt_amt = FmtAmt($fld_amt);
  $month_total  += $fmt_amt;
  $totals[$tot_num] += $fmt_amt;
  return $fmt_amt;
}
function GetDec($value) {
  if ($value == null || (string)$value == '')
return 0;
  else
return $value;
}
function FmtAmt($amt) {
  if ((string)$amt == '18.:') $amt = '19';  // another workaround for
the total
  $cred = '';
  if ($amt < 0) {
$amt  = 0 - $amt;
$cred = 'CR';
  }
  // $amt = number_format($amt, 2) . $cred;  // uncomment this comment
out next line to see bug
  $ret = stupid_php($amt) . $cred;
  return $ret;
}
// this is my workaround which works if the value doesn't already have
the stupid colon in it
function stupid_php($val) {
  $len = strlen($val);
  if ($len == 0)
return $val;
  if (strpos($val, '.') == false)
return $val . '.00';
  // for 123.4  len=5 pos=3 return 123.45
  if (strpos($val, '.') == $len - 2)
return $val . '0';
  if (strpos($val, '.') < $len - 2)
return round($val, 2);
  return $val;
}
function jsi_db_error($query, $errno, $error) {
  exit ('**Database Error (' .$errno. ') ' .$error. ' Query=[' .$query.
'] **');
}

$db_name = 'rent_2009';
$link  = odbc_connect($db_name, 'user', 'pw') 
  or jsi_db_error('Connect', odbc_errormsg(), odbc_error() );
$query = 'SELECT * FROM [Nov$A3:Z43] WHERE Lot = 11';
$result = odbc_exec($link, $query) or jsi_db_error($query,
odbc_errormsg(), odbc_error());
echo FmtFieldAmt(6, 'Late Fee');
ec

#47418 [Com]: number_format misbehaving with some values

2010-02-12 Thread tdietsche at comcast dot net
 ID:   47418
 Comment by:   tdietsche at comcast dot net
 Reported By:  cu19 at gmx dot de
 Status:   Open
 Bug Type: *Math Functions
 Operating System: Win7
 PHP Version:  5.3.1
 New Comment:

In case it might help, here is my php config (on WinXP SP3):


  PHP Version 5.3.1


System  Windows NT DIY2004 5.1 build 2600 (Windows XP Professional
Service Pack 3) i586
Build Date  Nov 19 2009 10:16:45
CompilerMSVC6 (Visual C++ 6.0)
Architecturex86
Configure Command   cscript /nologo configure.js
"--enable-snapshot-build" "--disable-isapi" "--enable-debug-pack"
"--disable-isapi"
"--with-pdo-oci=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8=D:\php-sdk\oracle\instantclient10\sdk,shared"
"--with-oci8-11g=D:\php-sdk\oracle\instantclient11\sdk,shared"
"--enable-object-out-dir=../obj/"
Server API  Apache 2.0 Handler
Virtual Directory Support   enabled
Configuration File (php.ini) Path   C:\WINDOWS
Loaded Configuration File   C:\PHP\php.ini
Scan this dir for additional .ini files (none)
Additional .ini files parsed(none)
PHP API 20090626
PHP Extension   20090626
Zend Extension  220090626
Zend Extension BuildAPI220090626,TS,VC6
PHP Extension Build API20090626,TS,VC6
Debug Build no
Thread Safety   enabled
Zend Memory Manager enabled
Zend Multibyte Support  disabled
IPv6 Supportenabled
Registered PHP Streams  php, file, glob, data, http, ftp, zip,
compress.zlib, compress.bzip2, https, ftps, phar
Registered Stream Socket Transports tcp, udp, ssl, sslv3, sslv2, tls
Registered Stream Filters   convert.iconv.*, string.rot13,
string.toupper, string.tolower, string.strip_tags, convert.*,
consumed,
dechunk, zlib.*, bzip2.*


Previous Comments:


[2010-02-12 13:19:29] tdietsche at comcast dot net

/* 
set up an Excel 97-2003 spreadsheet with a worksheet 'Nov'
and the row headers below on row 3
then add a row 14 with "John Smith" in Tenant, "11" in Lot, and "19" in
Late Fee.
Late fee should be number format with 2 decimals and comma thousands
separator format.
Create an odbc system DSN called "rent_2009" linked to it.
Then run this script against it, I have stripped it down but I think it
will show the problem.
note this will NOT show the problem if you just supply variable values
directly, it has to come
from excel and has something to do with the (string) casting of values
that excel thinks are numbers.
somehow the float and string are getting goofed up. Even when I fixed
the value, the total it was
being added to still had the problem until I hardwired a second test on
"18.:0" to fix that. Jeez.

(row headers):
Tenant
Lot
Prev Bal
Rent
LP Gas
Taxes
Garbage
Elec CR
Mowing
Late Fee
Misc
Deposit
New Bal
Check
Cash
Mail
Bal Fwd
Last Mon
This Mon
Change
Factor
Gallons
Rate/Gal
LP Amt
NOTES
Misc Desc

*/
$result= '';
$month_total = 0;
$totals  = array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);

function FmtFieldAmt($tot_num, $field_name) {
  global $result, $month_total, $totals;
  $res = odbc_result($result, $field_name);
  $fld_amt = GetDec($res);
  $fmt_amt = FmtAmt($fld_amt);
  $month_total  += $fmt_amt;
  $totals[$tot_num] += $fmt_amt;
  return $fmt_amt;
}
function GetDec($value) {
  if ($value == null || (string)$value == '')
return 0;
  else
return $value;
}
function FmtAmt($amt) {
  if ((string)$amt == '18.:') $amt = '19';  // another workaround for
the total
  $cred = '';
  if ($amt < 0) {
$amt  = 0 - $amt;
$cred = 'CR';
  }
  // $amt = number_format($amt, 2) . $cred;  // uncomment this comment
out next line to see bug
  $ret = stupid_php($amt) . $cred;
  return $ret;
}
// this is my workaround which works if the value doesn't already have
the stupid colon in it
function stupid_php($val) {
  $len = strlen($val);
  if ($len == 0)
return $val;
  if (strpos($val, '.') == false)
return $val . '.00';
  // for 123.4  len=5 pos=3 return 123.45
  if (strpos($val, '.') == $len - 2)
return $val . '0';
  if (strpos($val, '.') < $len - 2)
return round($val, 2);
  return $val;
}
function jsi_db_error($query, $errno, $error) {
  exit ('**Database Error (' .$errno. ') ' .$error. ' Query=[' .$query.
'] **');
}

$db_name = 'rent_2009';
$link  = odbc_connect($db_name, 'user', 'pw') 
  or jsi_db_error('Connect', odbc_errormsg(), odbc_error() );
$query = 'SELECT * FROM [Nov$A3:Z43] WHERE Lot = 11';
$result = odbc_exec($link, $query) or jsi_db_error($query,
odbc_errormsg(), odbc_error());
echo FmtFieldAmt(6, 'Late Fee');
echo FmtAmt($totals[6]);



[2010-02-12 11:55:25] cu19 at gmx dot de

That's nothing different, but exactly the same problem as I described
from the beginning.

This is the function that I currently use as a workaround. It works
fine, but I would prefer php doing this itself...

function my_number_format 

#50969 [Bgs]: operator overloading for classes

2010-02-12 Thread sylvain at abstraction dot fr
 ID:   50969
 User updated by:  sylvain at abstraction dot fr
 Reported By:  sylvain at abstraction dot fr
 Status:   Bogus
 Bug Type: Feature/Change Request
 Operating System: all
 PHP Version:  5.3.2RC1
 New Comment:

Well it is maybe implemented but it's beta and has not been updated 
for over 3 years. It is not usable in a 
production environment.

Regarding your point that it is not readable, objects implementing 
Iterator can be used with the foreach 
statement (which is an overloading) and for objects with multiples 
propertiesn you don't know what is done 
unless you read the code.

So, I don't see why we could not have overator overloading already 
having foreach overloading.

Things can get "funny" with overloading, yes, but that's not a reason 
to not implement it. You can't state you 
won't allow something because some people will not use it correctly, 
in that case, you allow nothing and you 
don't implement a dynamically weak typed language. It is up to the 
developer to secure its implementation. You 
must have a little faith in him.

Here an exemple of what I have in mind based on the Iterator model :

interface OperatorOverloading
{
public function __add($object);
public function __substract($object);
public function __multiply($object);
public function __divide($object);
public function __increment();
public function __decrement();
}

class foo implements OperatorOverloading
{
private $anynumber = 0;

public function __add($object)
{
if (!$object instanceof __CLASS__)
{
throw new Exception('Come on !!!');
}

$return = new foo();
$return->anynumber = $this->anynumber + $object-
>anynumber;

return $return;
}

public function __increment()
{
$this->anynumber++;
}

public function __decrement()
{
$this->anynumber--;
}

public function __substract($object)
{
throw new Exception('not implemented');
}

public function __divide($object)
{
throw new Exception('not implemented');
}

public function __multiply($object)
{
throw new Exception('not implemented');
}
}

Regards.


Previous Comments:


[2010-02-08 23:54:47] johan...@php.net

Well it is implemented, as you can see when following the link, I
myself once created a patch to make it a bit nicer in syntax but it will
never be implemented (as far as never goes)

And well the issue, in the most simple form, is something like this:

function foo() {
return bar() + baz();
}

In today's world during are view you can say "this will return a
numeric value"with operator overloading you can say "this will return
something or maybe fail"

Becomes especially "funny" with

return bar() + 4;

Sure there's convention and comments and things but that won't help and
you can always do

   return bar()->add(baz());

or

   return someclass::add(bar(), baz());

which makes the intention clear. Yes $a + $b + $c + $d might be bit
nicer to read than the long form - but only as long as you know what
types you have ...



[2010-02-08 23:15:17] sylvain at abstraction dot fr

I'm not particularly aware of operator overloading in other language
but I don't see why it would be less readable in PHP than in any other
language as the only way to know what is happening is to read the code
of the method overloading the operator.

Anyhow, do I have to take as official PHP Team position that you won't
implement it ?



[2010-02-08 22:59:25] johan...@php.net

Operator overloading in a dynamically weak typed language is bad as
reading code gives no information what's happening. If you really want
it go to http://pecl.php.net/operator maybe that still works.



[2010-02-08 22:49:23] sylvain at abstraction dot fr

Description:

I would like to know what is the current PHP team position about
operator overloading in PHP for classes.

Operator overloading has been stated Bogus in
http://bugs.php.net/bug.php?id=9331 but it was more than two years ago.

I think it would be nice to have a discussion about that topic. If you
recently had one I would be interested if you could indicate me where I
can find it.

Best Regards.






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



#47418 [Com]: number_format misbehaving with some values

2010-02-12 Thread tdietsche at comcast dot net
 ID:   47418
 Comment by:   tdietsche at comcast dot net
 Reported By:  cu19 at gmx dot de
 Status:   Open
 Bug Type: *Math Functions
 Operating System: Win7
 PHP Version:  5.3.1
 New Comment:

/* 
set up an Excel 97-2003 spreadsheet with a worksheet 'Nov'
and the row headers below on row 3
then add a row 14 with "John Smith" in Tenant, "11" in Lot, and "19" in
Late Fee.
Late fee should be number format with 2 decimals and comma thousands
separator format.
Create an odbc system DSN called "rent_2009" linked to it.
Then run this script against it, I have stripped it down but I think it
will show the problem.
note this will NOT show the problem if you just supply variable values
directly, it has to come
from excel and has something to do with the (string) casting of values
that excel thinks are numbers.
somehow the float and string are getting goofed up. Even when I fixed
the value, the total it was
being added to still had the problem until I hardwired a second test on
"18.:0" to fix that. Jeez.

(row headers):
Tenant
Lot
Prev Bal
Rent
LP Gas
Taxes
Garbage
Elec CR
Mowing
Late Fee
Misc
Deposit
New Bal
Check
Cash
Mail
Bal Fwd
Last Mon
This Mon
Change
Factor
Gallons
Rate/Gal
LP Amt
NOTES
Misc Desc

*/
$result= '';
$month_total = 0;
$totals  = array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);

function FmtFieldAmt($tot_num, $field_name) {
  global $result, $month_total, $totals;
  $res = odbc_result($result, $field_name);
  $fld_amt = GetDec($res);
  $fmt_amt = FmtAmt($fld_amt);
  $month_total  += $fmt_amt;
  $totals[$tot_num] += $fmt_amt;
  return $fmt_amt;
}
function GetDec($value) {
  if ($value == null || (string)$value == '')
return 0;
  else
return $value;
}
function FmtAmt($amt) {
  if ((string)$amt == '18.:') $amt = '19';  // another workaround for
the total
  $cred = '';
  if ($amt < 0) {
$amt  = 0 - $amt;
$cred = 'CR';
  }
  // $amt = number_format($amt, 2) . $cred;  // uncomment this comment
out next line to see bug
  $ret = stupid_php($amt) . $cred;
  return $ret;
}
// this is my workaround which works if the value doesn't already have
the stupid colon in it
function stupid_php($val) {
  $len = strlen($val);
  if ($len == 0)
return $val;
  if (strpos($val, '.') == false)
return $val . '.00';
  // for 123.4  len=5 pos=3 return 123.45
  if (strpos($val, '.') == $len - 2)
return $val . '0';
  if (strpos($val, '.') < $len - 2)
return round($val, 2);
  return $val;
}
function jsi_db_error($query, $errno, $error) {
  exit ('**Database Error (' .$errno. ') ' .$error. ' Query=[' .$query.
'] **');
}

$db_name = 'rent_2009';
$link  = odbc_connect($db_name, 'user', 'pw') 
  or jsi_db_error('Connect', odbc_errormsg(), odbc_error() );
$query = 'SELECT * FROM [Nov$A3:Z43] WHERE Lot = 11';
$result = odbc_exec($link, $query) or jsi_db_error($query,
odbc_errormsg(), odbc_error());
echo FmtFieldAmt(6, 'Late Fee');
echo FmtAmt($totals[6]);


Previous Comments:


[2010-02-12 11:55:25] cu19 at gmx dot de

That's nothing different, but exactly the same problem as I described
from the beginning.

This is the function that I currently use as a workaround. It works
fine, but I would prefer php doing this itself...

function my_number_format ($number, $decimals=0, $dec_point=',',
$thousands_sep='.') {
$string = number_format($number, $decimals, $dec_point,
$thousands_sep);
$pos = strlen($string) - 1;
$increase = false;
while ($pos >= 0) {
if (($increase) and (is_numeric($string{$pos}))) {
$string{$pos} = chr(ord($string{$pos}) + 1);
$increase = false;
}
if ($string{$pos} == ':') {
$string{$pos} = '0';
$increase = true;
}
$pos--;
}
if ($increase)
$string = '1' . $string;
return $string;
}



[2010-02-12 11:37:38] paj...@php.net

For the garbage problem, that's something else. 

Can you provide a reproduce script (with data) please?



[2010-02-12 11:31:41] tdietsche at comcast dot net

this sure IS a bug, scott_mac you need to wake up, if this is the best
that php handles floating point then it is worthless. In reading a value
of "19" from an excel spreadsheet via odbc, it formats it as "18.:0"
which is pure garbage and a bug to me. How can you defend that?
I can send my code if you want.



[2009-02-25 01:00:01] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, 

#51026 [NEW]: ssl not working

2010-02-12 Thread fuxa_kos at unihost dot cz
From: fuxa_kos at unihost dot cz
Operating system: Linux
PHP version:  5.3.1
PHP Bug Type: MySQLi related
Bug description:  ssl not working

Description:

ssl connection not working, same code with 5.2.12 working well.
With reference to bug 49234, I have support [33] => ssl_set.

mysql client working well too.
mysql ... --ssl-ca=cert/mysql-cacert.pem --ssl-cert=cert/client-cert.pem
--ssl-key=cert/client-key.pem
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 116395
Server version: 5.0.90-community-log MySQL Community Edition (GPL)
mysql> SHOW STATUS LIKE 'Ssl_cipher';
+---++
| Variable_name | Value  |
+---++
| Ssl_cipher| DHE-RSA-AES256-SHA |
+---++
1 row in set (0.00 sec)

from phpinfo
mysqli

MysqlI Support => enabled
Client API library version => 5.1.42
Active Persistent Links => 0
Inactive Persistent Links => 0
Active Links => 0
Client API header version => 5.1.42
MYSQLI_SOCKET => /var/lib/mysql/mysql.sock

Directive => Local Value => Master Value
mysqli.allow_local_infile => Off => Off
mysqli.allow_persistent => On => On
mysqli.default_host => no value => no value
mysqli.default_port => 3306 => 3306
mysqli.default_pw => no value => no value
mysqli.default_socket => no value => no value
mysqli.default_user => no value => no value
mysqli.max_links => Unlimited => Unlimited
mysqli.max_persistent => Unlimited => Unlimited
mysqli.reconnect => Off => Off

Client is Mysql 5.1 and server is Mysql 5.0. But same for 5.0 Mysql 
client. In case PHP 5.2 Mysql client is 5.0.

Reproduce code:
---
ssl_set('./cert/client-key.pem', './cert/client-cert.pem',
'./cert/mysql-cacert.pem', null, null);
$mysqli->real_connect('removed', '', '', '');
if ($r = $mysqli->query("SHOW STATUS LIKE 'Ssl_cipher'")) {
var_dump($r->fetch_row());
}
echo $mysqli->error."\n";
echo $mysqli->errno."\n";

Expected result:

something like this for Ssl_cipher
array(2) {
  [0]=>
  string(10) "Ssl_cipher"
  [1]=>
  string(18) "DHE-RSA-AES256-SHA"
}

and no errors.

Actual result:
--
Warning: mysqli::ssl_set(): invalid object or resource mysqli

with MYSQLI_CLIENT_SSL
Can't connect to MySQL server on 'removed' (113)
errno = 2003
 
without MYSQLI_CLIENT_SSL
Warning: mysqli::real_connect(): (28000/1045): Access denied for 
user 'removed' (using password: YES)
errno = 1045

ssl_set() in this case returns NULL, not true as doc says.

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



#47418 [Fbk->Opn]: number_format misbehaving with some values

2010-02-12 Thread cu19 at gmx dot de
 ID:   47418
 User updated by:  cu19 at gmx dot de
 Reported By:  cu19 at gmx dot de
-Status:   Feedback
+Status:   Open
 Bug Type: *Math Functions
-Operating System: WinXP SP3
+Operating System: Win7
-PHP Version:  5.3CVS-2009-02-17 (CVS)
+PHP Version:  5.3.1
 New Comment:

That's nothing different, but exactly the same problem as I described
from the beginning.

This is the function that I currently use as a workaround. It works
fine, but I would prefer php doing this itself...

function my_number_format ($number, $decimals=0, $dec_point=',',
$thousands_sep='.') {
$string = number_format($number, $decimals, $dec_point,
$thousands_sep);
$pos = strlen($string) - 1;
$increase = false;
while ($pos >= 0) {
if (($increase) and (is_numeric($string{$pos}))) {
$string{$pos} = chr(ord($string{$pos}) + 1);
$increase = false;
}
if ($string{$pos} == ':') {
$string{$pos} = '0';
$increase = true;
}
$pos--;
}
if ($increase)
$string = '1' . $string;
return $string;
}


Previous Comments:


[2010-02-12 11:37:38] paj...@php.net

For the garbage problem, that's something else. 

Can you provide a reproduce script (with data) please?



[2010-02-12 11:31:41] tdietsche at comcast dot net

this sure IS a bug, scott_mac you need to wake up, if this is the best
that php handles floating point then it is worthless. In reading a value
of "19" from an excel spreadsheet via odbc, it formats it as "18.:0"
which is pure garbage and a bug to me. How can you defend that?
I can send my code if you want.



[2009-02-25 01:00:01] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2009-02-17 11:20:31] scott...@php.net

sc...@skinny [~] $ php -r 'var_dump(number_format(3.9, 2));'
string(4) "3.90"

Can't reproduce this on Linux.



[2009-02-17 10:35:08] cu19 at gmx dot de

I don't think it's a problem with limited precision but rather about
the function itself. I think a float should be able to represent 3
digits without a problem. The hex representation of the float that is to
be formatted is 0x4078, which equals to about 3.896.

I think number_format should be able to round this to '3.90' instead of
displaying it as '3.8:'



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

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



#47418 [NoF->Fbk]: number_format misbehaving with some values

2010-02-12 Thread pajoye
 ID:   47418
 Updated by:   paj...@php.net
 Reported By:  cu19 at gmx dot de
-Status:   No Feedback
+Status:   Feedback
 Bug Type: *Math Functions
 Operating System: WinXP SP3
 PHP Version:  5.3CVS-2009-02-17 (CVS)
 New Comment:

For the garbage problem, that's something else. 

Can you provide a reproduce script (with data) please?


Previous Comments:


[2010-02-12 11:31:41] tdietsche at comcast dot net

this sure IS a bug, scott_mac you need to wake up, if this is the best
that php handles floating point then it is worthless. In reading a value
of "19" from an excel spreadsheet via odbc, it formats it as "18.:0"
which is pure garbage and a bug to me. How can you defend that?
I can send my code if you want.



[2009-02-25 01:00:01] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2009-02-17 11:20:31] scott...@php.net

sc...@skinny [~] $ php -r 'var_dump(number_format(3.9, 2));'
string(4) "3.90"

Can't reproduce this on Linux.



[2009-02-17 10:35:08] cu19 at gmx dot de

I don't think it's a problem with limited precision but rather about
the function itself. I think a float should be able to represent 3
digits without a problem. The hex representation of the float that is to
be formatted is 0x4078, which equals to about 3.896.

I think number_format should be able to round this to '3.90' instead of
displaying it as '3.8:'



[2009-02-17 10:18:32] scott...@php.net

Floating point values have a limited precision. Hence a value might 
not have the same string representation after any processing. That also
includes writing a floating point value in your script and directly 
printing it without any mathematical operations.

If you would like to know more about "floats" and what IEEE
754 is, read this:
http://docs.sun.com/source/806-3568/ncg_goldberg.html
 
Thank you for your interest in PHP.

It's the way floating point numbers work in computers, the canned
response gives you a link to read about this some more.



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

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



#47418 [Com]: number_format misbehaving with some values

2010-02-12 Thread tdietsche at comcast dot net
 ID:   47418
 Comment by:   tdietsche at comcast dot net
 Reported By:  cu19 at gmx dot de
 Status:   No Feedback
 Bug Type: *Math Functions
 Operating System: WinXP SP3
 PHP Version:  5.3CVS-2009-02-17 (CVS)
 New Comment:

this sure IS a bug, scott_mac you need to wake up, if this is the best
that php handles floating point then it is worthless. In reading a value
of "19" from an excel spreadsheet via odbc, it formats it as "18.:0"
which is pure garbage and a bug to me. How can you defend that?
I can send my code if you want.


Previous Comments:


[2009-02-25 01:00:01] php-bugs at lists dot php dot net

No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".



[2009-02-17 11:20:31] scott...@php.net

sc...@skinny [~] $ php -r 'var_dump(number_format(3.9, 2));'
string(4) "3.90"

Can't reproduce this on Linux.



[2009-02-17 10:35:08] cu19 at gmx dot de

I don't think it's a problem with limited precision but rather about
the function itself. I think a float should be able to represent 3
digits without a problem. The hex representation of the float that is to
be formatted is 0x4078, which equals to about 3.896.

I think number_format should be able to round this to '3.90' instead of
displaying it as '3.8:'



[2009-02-17 10:18:32] scott...@php.net

Floating point values have a limited precision. Hence a value might 
not have the same string representation after any processing. That also
includes writing a floating point value in your script and directly 
printing it without any mathematical operations.

If you would like to know more about "floats" and what IEEE
754 is, read this:
http://docs.sun.com/source/806-3568/ncg_goldberg.html
 
Thank you for your interest in PHP.

It's the way floating point numbers work in computers, the canned
response gives you a link to read about this some more.



[2009-02-17 10:13:49] cu19 at gmx dot de

After some additional recherche, it seems to me that the value is first
internally represented as '3.89'. Then, the function checks the
truncated digit which is larger than 5. So the last digit in the result
is increased by one. In ASCII, after the '9' comes the ':', so when the
last char of '3.89' is increased by one, it becomes '3.8:'. So when
increasing the last digit there must be checked if it's smaller than 9.

What I don't understand is why it only occurs sometimes...

Don't know the PHP sources and where to look for this, so I kindly ask
someone to look after this function.



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

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



#51025 [NEW]: Dynamic loading disabled when cross compiling

2010-02-12 Thread ncoesel at dealogic dot nl
From: ncoesel at dealogic dot nl
Operating system: Linux
PHP version:  5.2.12
PHP Bug Type: *Compile Issues
Bug description:  Dynamic loading disabled when cross compiling

Description:

For some reason dynamic loading is disabled when cross compiling (version
5.2.6 -sorry can't upgrade-) altough libdl is present and properly
detected. Or is this some automake/autoconf bug? When I modify configure to
skip the cross compiling test, dynamic loading works just fine on a mipsel
(MIPS little endian) platform.


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



#38805 [Com]: PDO Truncates Text from SQL Server Text Data Type Field

2010-02-12 Thread philipp at servicemail24 dot de
 ID:   38805
 Comment by:   philipp at servicemail24 dot de
 Reported By:  gkrajci at arescorporation dot com
 Status:   Assigned
 Bug Type: PDO related
 Operating System: Windows NT PBMA-WB2 5.2 build 37
 PHP Version:  5.1.6
 Assigned To:  sfox
 New Comment:

This problem is actually fixed in cvs:

http://www.mail-archive.com/php-...@lists.php.net/msg40731.html
http://www.mail-archive.com/php-...@lists.php.net/msg40711.html

Here is the working source code:

http://cvs.php.net/viewvc.cgi/php-src/ext/pdo_dblib/

I have no idea why these fixes aren't included in the 5.2 and 5.3
releases!

@sfox can you ensure that pdo_dblib is updated with the release of
5.2.13 and 5.3.2?


Previous Comments:


[2010-02-11 15:40:43] philipp at servicemail24 dot de

php 5.3.2 dotdeb still suffers from this problem.

does this fix help?

"Possible fix: remove "case SQLTEXT" from
ext/pdo_dblib/dblib_stmt.c:execute and let it fall though to default."



[2010-01-22 22:51:02] ssufficool at gmail dot com

I imagine the problem is that PDO DBLIB just mem-copies the first
packet of TEXT without calling dbgettext() to retrieve the remainder.

MSSQL handles TEXT fields using dbconvert() which may call dbgettext()
downstream.

Possible fix: remove "case SQLTEXT" from
ext/pdo_dblib/dblib_stmt.c:execute and let it fall though to default.



[2010-01-10 23:22:50] ka...@php.net

Steph, does this need any additional changes to pdo_mssql/pdo_dblib?
And what exactly should be documented?



[2009-09-02 15:28:50] aballard at gmail dot com

According to the SQL Server documenation, SET TEXTSIZE { number } by
itself is not sufficient. That's why the original mssql library has two
configuration directives: mssql.textlimit and mssql.textsize

Since PDO is configured not to use configuration directives, it would
be nice if the pdo_mssql driver added two driver_options to configure
these values.


A quote from SQL Server Books Online:


Setting SET TEXTSIZE affects the @@TEXTSIZE function.

The DB-Library variable DBTEXTLIMIT also limits the size of text data
returned with a SELECT statement. If DBTEXTLIMIT is set to a smaller
size than TEXTSIZE, only the amount specified by DBTEXTLIMIT is
returned. For more information, see "Programming DB-Library for C" in
SQL Server Books Online.

The SQL Server ODBC driver and Microsoft OLE DB Provider for SQL Server
automatically set TEXTSIZE to 2147483647 when connecting.

The setting of set TEXTSIZE is set at execute or run time and not at
parse time.



[2009-07-27 10:52:45] danhen at web dot de

When using PDO_MSSQL with PHP 5.3 (Not PDO_ODBC - queries aren't
compatible in many cases - especially those with placeholders)
pdo::query(SET TEXTSIZE 2147483647) works fine with MSSQL 2008. PDO_ODBC
isn't a good replacement.



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

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