Bug #62427 [Nab]: PCRE invalid "\k" sequence does not cause warning or error

2012-06-27 Thread danielklein at airpost dot net
Edit report at https://bugs.php.net/bug.php?id=62427&edit=1

 ID: 62427
 User updated by:danielklein at airpost dot net
 Reported by:danielklein at airpost dot net
 Summary:PCRE invalid "\k" sequence does not cause warning or
 error
 Status: Not a bug
 Type:   Bug
 Package:PCRE related
 PHP Version:5.4.4
 Block user comment: N
 Private report: N

 New Comment:

I see... PHP 5.4.4 is using PCRE 8.12 (according to my phpinfo();) This 
particular bug was fixed in PCRE 8.13 :( Missed it by >that< much...
http://pcre.org/changelog.txt - Search for \k

Can PHP be updated to use the latest PCRE?

P.S. I thought you were only allowed to report issues against the current 
version of PHP? PCRE 8.02 was included in PHP 5.3.3 :p

P.P.S. The documentation is out of date on the following page:
http://www.php.net/manual/en/pcre.installation.php


Previous Comments:

[2012-06-27 13:16:00] fel...@php.net

Not a PHP bug. The error depends on the PCRE library version.

$ pcretest 
PCRE version 8.02 2010-03-19

  re> /\k/
data> a
No match
  re> /\g/
Failed: a numbered reference must not be zero at offset 1


[2012-06-27 03:13:13] ras...@php.net

For reference, the command pcretest tool that comes with PCRE-8.30 gives this:

  re> /\k/
Failed: \k is not followed by a braced, angle-bracketed, or quoted name at 
offset 
2
  re> /\g/
Failed: a numbered reference must not be zero at offset 1


[2012-06-27 01:22:24] danielklein at airpost dot net

Description:

The "\k" escape must be followed by 'name',  or {name}. A PCRE regex that 
contains "\k" without the properly quoted name will compile without an error 
and will always fail as "\k" can never (as far as I know) match anything in the 
subject string. It is almost identical to "\g", except "\g" also allows "\gn", 
"\g{n}" or "\g{-n}" where "n" is any positive decimal number.

I have been unable to test PCRE directly (i.e. via the command line, not 
through PHP) as I can't compile it on my computer. I have looked through the 
source code and the test results, and from that it seems to be working 
correctly. Although I'm not 100% sure, I think this bug is specific to PHP.

Test script:
---


Expected result:

Warning: preg_match(): Compilation failed: **something about name missing in \k 
back-reference** at offset 1 in test.php on line 3
 bool(false)
Warning: preg_match(): Compilation failed: a numbered reference must not be 
zero at offset 1 in test.php on line 3
 bool(false)

Actual result:
--
int(0) 
Warning: preg_match(): Compilation failed: a numbered reference must not be 
zero at offset 1 in test.php on line 3
 bool(false)






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


Bug #61665 [Opn->Fbk]: include on stream wrapper results in wsod

2012-06-27 Thread pollita
Edit report at https://bugs.php.net/bug.php?id=61665&edit=1

 ID: 61665
 Updated by: poll...@php.net
 Reported by:btmash at gmail dot com
 Summary:include on stream wrapper results in wsod
-Status: Open
+Status: Feedback
 Type:   Bug
 Package:Streams related
 Operating System:   Ubuntu 10.04
 PHP Version:5.3.10
 Block user comment: N
 Private report: N



Previous Comments:

[2012-06-28 00:56:28] poll...@php.net

Hi, could you paste the wrapper code again? That link is invalid (the content 
hosting site went down).  Thanks!


[2012-04-19 08:08:15] btmash at gmail dot com

I'm setting it back to open since I've provided feedback.


[2012-04-09 23:29:13] btmash at gmail dot com

I've pasted a version of the class at http://paste.pocoo.org/show/578721/ since 
it is longer than 20 lines.

Please note that a large chunk of this is the drupal stream wrapper interface 
and at the bottom is the stream class that I implemented 'MyLocalStreamWrapper' 
which returns back the directory it is currently in. I perform an include to a 
info.php file which consists of:
"
http://drupal.org/project/configuration) that provided its own contributed 
stream wrapper to find the local configuration directory (so it was in the 
format 'config://path/to/file' - the implementation can be seen at 
http://drupalcode.org/project/configuration.git/blob/refs/heads/7.x-1.x:/configuration_stream.inc).
 On my local environment of running the site with the module (which runs php 
5.3.6), the configuration would be able to scan on files with the protocol 
without any issues. 

However, once I moved to my staging environment which runs php 5.3.10, I would 
end up with a wsod. The strange part was that the page returned a code 200 and 
nothing in the error log. I made sure that allow_url_fopen was enabled and the 
protocols actually registered so it should have worked correctly. Moreover, 
using file_exists and is_file work to ensure the file exists so that meant the 
file was being found the first time around.

For now, my workaround has been to use drupal's functions to get the stream 
converted correctly (see http://drupal.org/files/config-stream.patch as my 
workaround for the module to work) but problem seems to stem from PHP which is 
why I am filing my issue here. Any help that can be provided would be greatly 
appreciated.

Test script:
---
Implement a simple stream wrapper to a file in local (lets call it local).

Create a php file to include from somewhere (called test_include.inc).

Have the line 'include local://path/to/test_include.inc'.

Expected result:

It should result in a code 200 but also a wsod.

Actual result:
--
The script should be correctly included.






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


Bug #61665 [Com]: include on stream wrapper results in wsod

2012-06-27 Thread poll...@php.net
Edit report at https://bugs.php.net/bug.php?id=61665&edit=1

 ID: 61665
 Comment by: poll...@php.net
 Reported by:btmash at gmail dot com
 Summary:include on stream wrapper results in wsod
 Status: Open
 Type:   Bug
 Package:Streams related
 Operating System:   Ubuntu 10.04
 PHP Version:5.3.10
 Block user comment: N
 Private report: N

 New Comment:

Hi, could you paste the wrapper code again? That link is invalid (the content 
hosting site went down).  Thanks!


Previous Comments:

[2012-04-19 08:08:15] btmash at gmail dot com

I'm setting it back to open since I've provided feedback.


[2012-04-09 23:29:13] btmash at gmail dot com

I've pasted a version of the class at http://paste.pocoo.org/show/578721/ since 
it is longer than 20 lines.

Please note that a large chunk of this is the drupal stream wrapper interface 
and at the bottom is the stream class that I implemented 'MyLocalStreamWrapper' 
which returns back the directory it is currently in. I perform an include to a 
info.php file which consists of:
"
http://drupal.org/project/configuration) that provided its own contributed 
stream wrapper to find the local configuration directory (so it was in the 
format 'config://path/to/file' - the implementation can be seen at 
http://drupalcode.org/project/configuration.git/blob/refs/heads/7.x-1.x:/configuration_stream.inc).
 On my local environment of running the site with the module (which runs php 
5.3.6), the configuration would be able to scan on files with the protocol 
without any issues. 

However, once I moved to my staging environment which runs php 5.3.10, I would 
end up with a wsod. The strange part was that the page returned a code 200 and 
nothing in the error log. I made sure that allow_url_fopen was enabled and the 
protocols actually registered so it should have worked correctly. Moreover, 
using file_exists and is_file work to ensure the file exists so that meant the 
file was being found the first time around.

For now, my workaround has been to use drupal's functions to get the stream 
converted correctly (see http://drupal.org/files/config-stream.patch as my 
workaround for the module to work) but problem seems to stem from PHP which is 
why I am filing my issue here. Any help that can be provided would be greatly 
appreciated.

Test script:
---
Implement a simple stream wrapper to a file in local (lets call it local).

Create a php file to include from somewhere (called test_include.inc).

Have the line 'include local://path/to/test_include.inc'.

Expected result:

It should result in a code 200 but also a wsod.

Actual result:
--
The script should be correctly included.






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


Bug #36947 [Com]: HTTP stream wrapper does not treat all 2xx status codes as successful

2012-06-27 Thread poll...@php.net
Edit report at https://bugs.php.net/bug.php?id=36947&edit=1

 ID: 36947
 Comment by: poll...@php.net
 Reported by:Jared dot Williams1 at ntlworld dot com
 Summary:HTTP stream wrapper does not treat all 2xx status
 codes as successful
 Status: Open
 Type:   Bug
 Package:Streams related
 Operating System:   Win2000
 PHP Version:5.1.3RC2
 Block user comment: N
 Private report: N

 New Comment:

Could you elaborate on "not fixed" (preferably with a repro case)?  The code 
added by Mike in 2008 seems pretty liberal:


/* all status codes in the 2xx range are defined by the specification as 
successful;
 * all status codes in the 3xx range are for redirection, and so also should 
never
 * fail */
if (response_code >= 200 && response_code < 400) {
reqok = 1;


Previous Comments:

[2012-02-01 05:46:56] josh at joshbutts dot com

This does not appear to be fixed in 5.3.6 compiled from source on Mac OS 10.7


[2008-10-27 11:59:01] bj...@php.net

Fixed in PHP5.3, but I don't think it has been documented properly yet.
See: http://php.markmail.org/message/5rockhlt6hj7tzrb


[2006-04-02 13:39:17] Jared dot Williams1 at ntlworld dot com

Was raised on php internals ~year ago..

http://marc.theaimsgroup.com/?l=php-dev&m=111383344601864&w=2

http://marc.theaimsgroup.com/?l=php-dev&m=111384113712112&w=2

http://marc.theaimsgroup.com/?l=php-dev&m=111384249807034&w=2


[2006-04-02 13:20:04] Jared dot Williams1 at ntlworld dot com

Description:

PHP HTTP stream wrapper does not treat all http 2xx status codes as successful, 
making it impossible to use with WebDAV.








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


Bug #62432 [Opn->Csd]: ReflectionMethod random corrupt memory on high concurrent

2012-06-27 Thread johannes
Edit report at https://bugs.php.net/bug.php?id=62432&edit=1

 ID: 62432
 Updated by: johan...@php.net
 Reported by:xuefer at gmail dot com
 Summary:ReflectionMethod random corrupt memory on high
 concurrent
-Status: Open
+Status: Closed
 Type:   Bug
 Package:Reflection related
 Operating System:   Windows
 PHP Version:5.3.14
-Assigned To:
+Assigned To:johannes
 Block user comment: N
 Private report: N

 New Comment:

This was fixed. Not only in reflection but also in date, fileinfo, pdo, pdo, 
reflection, soap, spl, sqlite, sqlite3, tidy, xmlreader, xmlwriter, xsl and zip.

This was a 5.3-only issue, not in 5.4/master.


Previous Comments:

[2012-06-27 21:36:04] johan...@php.net

Automatic comment on behalf of johannes
Revision: 
http://git.php.net/?p=php-src.git;a=commit;h=b025b9d0cf9921d26fc4dad43cf26390d0a8c5dd
Log: Fix #62432 ReflectionMethod random corrupt memory on high concurrent


[2012-06-27 17:36:29] xuefer at gmail dot com

Description:

ReflectionMethod crash zend memory manager randomly on high concurrent


Configuration File (php.ini) Path   C:\Windows
Loaded Configuration File   (none)
Scan this dir for additional .ini files (none)
Additional .ini files parsed(none)
Zend Extension BuildAPI220090626,TS,VC9
PHP Extension Build API20090626,TS,VC9
Debug Build no
Thread Safety   enabled
Zend Memory Manager enabled

Configuration

apache2handler

Apache Version  Apache/2.2.22 (Win32) mod_ssl/2.2.22 OpenSSL/0.9.8t PHP/5.3.14

apache is loaded with module alias_module authz_host_module and php, nothing 
else

Test script:
---


ab.exe -n 3 -c 60 http://localhost/test.php
This is ApacheBench, Version 2.3 <$Revision: 655654 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

Benchmarking localhost (be patient)
Total of 983 requests completed
apr_poll: The timeout specified has expired (70007)


Expected result:

no crash

Actual result:
--
The thread 'Win32 Thread' (0x1e98) has exited with code 0 (0x0).
Unhandled exception at 0x69e2c7d7 (php5ts.dll) in httpd.exe: 0xC005: Access 
violation reading location 0x29bffacc.

>   php5ts.dll!_zend_mm_free_int(_zend_mm_heap * heap=0x0edf8a20, void * 
p=0x)  Line 2028C
php5ts.dll!_efree(void * ptr=0x023dd588)  Line 2361 + 0xa bytes C
php5ts.dll!_zval_dtor_func(_zval_struct * zvalue=0x023fe918)  Line 36 + 
0xc bytes   C
php5ts.dll!_zval_ptr_dtor(_zval_struct * * zval_ptr=0x10f00dbc)  Line 
447 + 0xc bytes C
php5ts.dll!_zend_hash_add_or_update(_hashtable * ht=0x10f00d80, const 
char * arKey=0x6a1b4d00, unsigned int nKeyLength=0x0006, void * 
pData=0x0995fab8, unsigned int nDataSize=0x0004, void * * pDest=0x, 
int flag=0x0001)  Line 237 + 0x6 bytes  C
php5ts.dll!zim_reflection_method___construct(int ht=0x0001, 
_zval_struct * return_value=0x10f02778, _zval_struct * * 
return_value_ptr=0x, _zval_struct * this_ptr=0x10f00d60, int 
return_value_used=0x, void * * * tsrm_ls=0x0efbb728)  Line 2532 C
php5ts.dll!zend_do_fcall_common_helper_SPEC(_zend_execute_data * 
execute_data=0x10f30080, void * * * tsrm_ls=0x0efbb701)  Line 320 + 0x41 bytes  
C
php5ts.dll!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(_zend_execute_data * 
execute_data=0x0005, void * * * tsrm_ls=0x0f0c4868)  Line 426   C
php5ts.dll!execute(_zend_op_array * op_array=0x10f00880, void * * * 
tsrm_ls=0x0efbb700)  Line 107 + 0xa bytes   C
php5ts.dll!zend_execute_scripts(int type=0x0008, void * * * 
tsrm_ls=0x0efbb728, _zval_struct * * retval=0x, int 
file_count=0x0003, ...)  Line 1237  C
php5ts.dll!php_execute_script(_zend_file_handle * 
primary_file=0x0995fe34, void * * * tsrm_ls=0x0efbb728)  Line 2308 + 0x12 bytes 
C
php5apache2_2.dll!php_handler(request_rec * r=0x0bc82100)  Line 669 + 
0xe bytes   C
libhttpd.dll!6ff02435() 
[Frames below may be incorrect and/or missing, no symbols loaded for 
libhttpd.dll]   
libhttpd.dll!6ff027c0() 
libhttpd.dll!6ff0f01e() 
libhttpd.dll!6ff0adbc() 
libhttpd.dll!6ff050a5() 
libhttpd.dll!6ff05363() 
libhttpd.dll!6ff1df6c() 
msvcrt.dll!74921287()   
msvcrt.dll!74921328()   
kernel32.dll!@BaseThreadInitThunk@12()  + 0x12 bytes
ntdll.dll!___RtlUserThreadStart@8()  + 0x27 bytes   
ntdll.dll!__RtlUserThreadStart@8()  + 0x1b bytes



-

Bug #62418 [Opn]: php-fpm master process crashes

2012-06-27 Thread rasmus
Edit report at https://bugs.php.net/bug.php?id=62418&edit=1

 ID: 62418
 Updated by: ras...@php.net
 Reported by:php at scratchspace dot com
 Summary:php-fpm master process crashes
 Status: Open
 Type:   Bug
 Package:FPM related
 Operating System:   CentOS 6.2 x86_x64
 PHP Version:5.3.14
 Block user comment: N
 Private report: N

 New Comment:

Not sure. Many people out there run with epoll without problems.


Previous Comments:

[2012-06-27 18:28:14] php at scratchspace dot com

We've been up and running for 24 hours with "events.mechanism = poll" and no 
problems. Let's give it a couple of days to be sure this workaround works. Is 
this 
issue specific to epoll and the way we have php-fpm configured (to use minimal 
resources), or is this is a bug in php-fpm that can ultimately be fixed?


[2012-06-26 06:10:02] ras...@php.net

Could you check if it is related to epoll? In your php-fpm.conf file, set:

events.mechanism = poll

to try with "poll" instead. You can also try setting it to "select"


[2012-06-26 05:56:45] php at scratchspace dot com

Description:

php-fpm master process crashes randomly on lightly loaded server running 
nginx/0.8.54 with various CMS applications. It is unknown how to reproduce the 
crash, but occurs in both php 5.3.13 and 5.3.14.

Actual result:
--
5.3.14 backtrace

Core was generated by `php-fpm:'.
Program terminated with signal 11, Segmentation fault.
#0  0x016b5300 in ?? ()
#1  0x006e02f3 in fpm_event_epoll_wait (queue=, 
timeout=)
at /usr/src/debug/php-5.3.14/sapi/fpm/fpm/events/epoll.c:143
#2  0x006d508f in fpm_event_loop (err=0) at /usr/src/debug/php-
5.3.14/sapi/fpm/fpm/fpm_events.c:401
#3  0x006d01f7 in fpm_run (max_requests=0x7fffd103136c) at 
/usr/src/debug/php-5.3.14/sapi/fpm/fpm/fpm.c:110
#4  0x006d79a4 in main (argc=1, argv=0x7fffd10334d8) at 
/usr/src/debug/php-5.3.14/sapi/fpm/fpm/fpm_main.c:1778







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


Bug #62418 [Fbk->Opn]: php-fpm master process crashes

2012-06-27 Thread php at scratchspace dot com
Edit report at https://bugs.php.net/bug.php?id=62418&edit=1

 ID: 62418
 User updated by:php at scratchspace dot com
 Reported by:php at scratchspace dot com
 Summary:php-fpm master process crashes
-Status: Feedback
+Status: Open
 Type:   Bug
 Package:FPM related
 Operating System:   CentOS 6.2 x86_x64
 PHP Version:5.3.14
 Block user comment: N
 Private report: N

 New Comment:

We've been up and running for 24 hours with "events.mechanism = poll" and no 
problems. Let's give it a couple of days to be sure this workaround works. Is 
this 
issue specific to epoll and the way we have php-fpm configured (to use minimal 
resources), or is this is a bug in php-fpm that can ultimately be fixed?


Previous Comments:

[2012-06-26 06:10:02] ras...@php.net

Could you check if it is related to epoll? In your php-fpm.conf file, set:

events.mechanism = poll

to try with "poll" instead. You can also try setting it to "select"


[2012-06-26 05:56:45] php at scratchspace dot com

Description:

php-fpm master process crashes randomly on lightly loaded server running 
nginx/0.8.54 with various CMS applications. It is unknown how to reproduce the 
crash, but occurs in both php 5.3.13 and 5.3.14.

Actual result:
--
5.3.14 backtrace

Core was generated by `php-fpm:'.
Program terminated with signal 11, Segmentation fault.
#0  0x016b5300 in ?? ()
#1  0x006e02f3 in fpm_event_epoll_wait (queue=, 
timeout=)
at /usr/src/debug/php-5.3.14/sapi/fpm/fpm/events/epoll.c:143
#2  0x006d508f in fpm_event_loop (err=0) at /usr/src/debug/php-
5.3.14/sapi/fpm/fpm/fpm_events.c:401
#3  0x006d01f7 in fpm_run (max_requests=0x7fffd103136c) at 
/usr/src/debug/php-5.3.14/sapi/fpm/fpm/fpm.c:110
#4  0x006d79a4 in main (argc=1, argv=0x7fffd10334d8) at 
/usr/src/debug/php-5.3.14/sapi/fpm/fpm/fpm_main.c:1778







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


Bug #62431 [Opn->Nab]: array_fill_keys must always return an array

2012-06-27 Thread nikic
Edit report at https://bugs.php.net/bug.php?id=62431&edit=1

 ID: 62431
 Updated by: ni...@php.net
 Reported by:gmblar+php at gmail dot com
 Summary:array_fill_keys must always return an array
-Status: Open
+Status: Not a bug
 Type:   Bug
 Package:Arrays related
 Operating System:   Linux
 PHP Version:5.4.4
 Block user comment: N
 Private report: N

 New Comment:

All PHP functions return NULL when called with incorrect parameters. This is 
nothing special about array_fill_keys(). As this is the same for all functions 
it is not specially mentioned on every single function docs page.


Previous Comments:

[2012-06-27 16:06:06] gmblar+php at gmail dot com

Description:

array_fill_keys must always return an array as described in 
http://de3.php.net/manual/en/function.array-fill-keys.php.

When call array_fill_keys with invalid arguments the function returns an 
invalid 
null!

Test script:
---
https://bugs.php.net/bug.php?id=62431&edit=1


[PHP-BUG] Bug #62433 [NEW]: Inconsistent behavior of RecursiveDirectoryIterator to dot files (. and ..)

2012-06-27 Thread miau dot jp at gmail dot com
From: miau dot jp at gmail dot com
Operating system: All
PHP version:  5.4.4
Package:  SPL related
Bug Type: Bug
Bug description:Inconsistent behavior of RecursiveDirectoryIterator to dot 
files (. and ..)

Description:

RecurisveDirectoryIterator skips dot files (. and ..) that appear on
the top of directory entries only. Since some file systems (e.g.: ext3,
FAT32)
doesn't sort directory entries, the behavior of RecursiveDirectoryIterator
is inconsistent.

RecursiveDirectoryIterator should either always skip dot files, or never
skip dot files. Otherwise many developer mistakenly assume that 
RecurisveDirectoryIterator always skips dot files, and add a bug to their
programs.



(tested on ext3 file system)

# mkdir test
# cd test
# cat <<\EOF >test.php
 /root/test/test.php
)

# touch 1 2 3 4 5
# ls -liaU
total 16
8315730 -rw-r--r-- 1 root root0  6月 28 02:16 2
8315733 -rw-r--r-- 1 root root0  6月 28 02:16 5
8314945 drwxr-x--- 8 root root 4096  6月 28 02:15 ..
8315727 drwxr-xr-x 2 root root 4096  6月 28 02:16 .
8315728 -rw-r--r-- 1 root root  114  6月 28 02:16 test.php
8315729 -rw-r--r-- 1 root root0  6月 28 02:16 1
8315731 -rw-r--r-- 1 root root0  6月 28 02:16 3
8315732 -rw-r--r-- 1 root root0  6月 28 02:16 4
# php test.php
/root/test
Array
(
[0] => /root/test/2
[1] => /root/test/5
[2] => /root/test/..
[3] => /root/test/.
[4] => /root/test/test.php
[5] => /root/test/1
[6] => /root/test/3
[7] => /root/test/4
)

(To ensure skippping dot files, construct the RecursiveDirectoryIterator
with SKIP_DOTS flag for now.)

# cat <<\EOF >test.php
 /root/test/2
[1] => /root/test/5
[2] => /root/test/test.php
[3] => /root/test/1
[4] => /root/test/3
[5] => /root/test/4
)



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



Bug #27163 [Com]: gethostbyname() returns server IP for non-existent hosts

2012-06-27 Thread s at finalclass dot net
Edit report at https://bugs.php.net/bug.php?id=27163&edit=1

 ID: 27163
 Comment by: s at finalclass dot net
 Reported by:turtle at rawx dot net
 Summary:gethostbyname() returns server IP for non-existent
 hosts
 Status: Not a bug
 Type:   Bug
 Package:Network related
 Operating System:   Linux 2.4.24
 PHP Version:4.3.5RC2
 Block user comment: N
 Private report: N

 New Comment:

Try removing this line:
domain YOUR_DOMAIN_NAMe
from /etc/resolve.conf file.
In my case this solved the problem.


Previous Comments:

[2004-02-05 21:26:00] il...@php.net

It works fine here, when it fails to resolve the original 
domain string is returned. If you get anything else it 
could be due to named issues on your system. 


[2004-02-05 15:13:09] turtle at rawx dot net

Description:

gethostbyname() is returning my own IP address for non-existent domain names. 
The expected behavior is that it will return the original name back to you.

Resolving a real domain returns it's correct IP address.

This issue affects other DNS resoluton commands too... for example, 
checkdnsrr('totallyfake456jh47r.com','A') returns TRUE.

Using local resolution commands, the expected result (NXDOMAIN) is returned:

/:~# host totallyfake456jh47r.com
Host totallyfake456jh47r.com not found: 3(NXDOMAIN)

This may similar (same?) as bug ID 21487.

PHP configuration: ./configure --with-apxs2=/www/bin/apxs 
--with-config-file-path=/etc --with-mcrypt --enable-ftp --with-gd=/usr/local 
--with-zlib-dir=/usr/local --with-jpeg-dir=/usr/local --with-png-dir=/usr/local 
--with-mysql --with-xml --enable-track-vars 

Reproduce code:
---
echo gethostbyname('totallyfake456jh47r.com');

Expected result:

totallyfake456jh47r.com

Actual result:
--
66.166.160.74

(my server's own IP)






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


[PHP-BUG] Bug #62432 [NEW]: ReflectionMethod random corrupt memory on high concurrent

2012-06-27 Thread xuefer at gmail dot com
From: xuefer at gmail dot com
Operating system: Windows
PHP version:  5.3.14
Package:  Reflection related
Bug Type: Bug
Bug description:ReflectionMethod random corrupt memory on high concurrent

Description:

ReflectionMethod crash zend memory manager randomly on high concurrent


Configuration File (php.ini) Path   C:\Windows
Loaded Configuration File   (none)
Scan this dir for additional .ini files (none)
Additional .ini files parsed(none)
Zend Extension BuildAPI220090626,TS,VC9
PHP Extension Build API20090626,TS,VC9
Debug Build no
Thread Safety   enabled
Zend Memory Manager enabled

Configuration

apache2handler

Apache Version  Apache/2.2.22 (Win32) mod_ssl/2.2.22 OpenSSL/0.9.8t
PHP/5.3.14

apache is loaded with module alias_module authz_host_module and php,
nothing 
else

Test script:
---


ab.exe -n 3 -c 60 http://localhost/test.php
This is ApacheBench, Version 2.3 <$Revision: 655654 $>
Copyright 1996 Adam Twiss, Zeus Technology Ltd, http://www.zeustech.net/
Licensed to The Apache Software Foundation, http://www.apache.org/

Benchmarking localhost (be patient)
Total of 983 requests completed
apr_poll: The timeout specified has expired (70007)


Expected result:

no crash

Actual result:
--
The thread 'Win32 Thread' (0x1e98) has exited with code 0 (0x0).
Unhandled exception at 0x69e2c7d7 (php5ts.dll) in httpd.exe: 0xC005:
Access 
violation reading location 0x29bffacc.

>   php5ts.dll!_zend_mm_free_int(_zend_mm_heap * heap=0x0edf8a20, void * 
p=0x)  Line 2028C
php5ts.dll!_efree(void * ptr=0x023dd588)  Line 2361 + 0xa bytes C
php5ts.dll!_zval_dtor_func(_zval_struct * zvalue=0x023fe918)  Line 36 + 
0xc bytes   C
php5ts.dll!_zval_ptr_dtor(_zval_struct * * zval_ptr=0x10f00dbc)  Line 
447 + 0xc bytes C
php5ts.dll!_zend_hash_add_or_update(_hashtable * ht=0x10f00d80, const 
char * arKey=0x6a1b4d00, unsigned int nKeyLength=0x0006, void * 
pData=0x0995fab8, unsigned int nDataSize=0x0004, void * *
pDest=0x, 
int flag=0x0001)  Line 237 + 0x6 bytes  C
php5ts.dll!zim_reflection_method___construct(int ht=0x0001, 
_zval_struct * return_value=0x10f02778, _zval_struct * * 
return_value_ptr=0x, _zval_struct * this_ptr=0x10f00d60, int 
return_value_used=0x, void * * * tsrm_ls=0x0efbb728)  Line 2532 C
php5ts.dll!zend_do_fcall_common_helper_SPEC(_zend_execute_data * 
execute_data=0x10f30080, void * * * tsrm_ls=0x0efbb701)  Line 320 + 0x41
bytes   
C
php5ts.dll!ZEND_DO_FCALL_BY_NAME_SPEC_HANDLER(_zend_execute_data * 
execute_data=0x0005, void * * * tsrm_ls=0x0f0c4868)  Line 426   C
php5ts.dll!execute(_zend_op_array * op_array=0x10f00880, void * * * 
tsrm_ls=0x0efbb700)  Line 107 + 0xa bytes   C
php5ts.dll!zend_execute_scripts(int type=0x0008, void * * * 
tsrm_ls=0x0efbb728, _zval_struct * * retval=0x, int 
file_count=0x0003, ...)  Line 1237  C
php5ts.dll!php_execute_script(_zend_file_handle * 
primary_file=0x0995fe34, void * * * tsrm_ls=0x0efbb728)  Line 2308 + 0x12
bytes   
C
php5apache2_2.dll!php_handler(request_rec * r=0x0bc82100)  Line 669 + 
0xe bytes   C
libhttpd.dll!6ff02435() 
[Frames below may be incorrect and/or missing, no symbols loaded for 
libhttpd.dll]   
libhttpd.dll!6ff027c0() 
libhttpd.dll!6ff0f01e() 
libhttpd.dll!6ff0adbc() 
libhttpd.dll!6ff050a5() 
libhttpd.dll!6ff05363() 
libhttpd.dll!6ff1df6c() 
msvcrt.dll!74921287()   
msvcrt.dll!74921328()   
kernel32.dll!@BaseThreadInitThunk@12()  + 0x12 bytes
ntdll.dll!___RtlUserThreadStart@8()  + 0x27 bytes   
ntdll.dll!__RtlUserThreadStart@8()  + 0x1b bytes


-- 
Edit bug report at https://bugs.php.net/bug.php?id=62432&edit=1
-- 
Try a snapshot (PHP 5.4):
https://bugs.php.net/fix.php?id=62432&r=trysnapshot54
Try a snapshot (PHP 5.3):
https://bugs.php.net/fix.php?id=62432&r=trysnapshot53
Try a snapshot (trunk):  
https://bugs.php.net/fix.php?id=62432&r=trysnapshottrunk
Fixed in SVN:
https://bugs.php.net/fix.php?id=62432&r=fixed
Fixed in SVN and need be documented: 
https://bugs.php.net/fix.php?id=62432&r=needdocs
Fixed in release:
https://bugs.php.net/fix.php?id=62432&r=alreadyfixed
Need backtrace:  
https://bugs.php.net/fix.php?id=62432&r=needtrace
Need Reproduce Script:   
https://bugs.php.net/fix.php?id=62432&r=needscript
Try newer version:   
https://bugs.php.net/fix.php?id=62432&r=oldversion
Not developer issue: 
https://bugs.php.net/fix.php?id=62432&r=support
Expected behavior:   
https://bugs.php.net/fix.php?id=62432&r=notwro

Bug #62313 [PATCH]: Zend\tests\errmsg_021.phpt fails

2012-06-27 Thread a...@php.net
Edit report at https://bugs.php.net/bug.php?id=62313&edit=1

 ID: 62313
 Patch added by: a...@php.net
 Reported by:a...@php.net
 Summary:Zend\tests\errmsg_021.phpt fails
 Status: Open
 Type:   Bug
 Package:Reproducible crash
 Operating System:   windows
 PHP Version:5.4Git-2012-06-13 (snap)
 Block user comment: N
 Private report: N

 New Comment:

The following patch has been added/updated:

Patch Name: 62313.patch
Revision:   1340818555
URL:
https://bugs.php.net/patch-display.php?bug=62313&patch=62313.patch&revision=1340818555


Previous Comments:

[2012-06-17 14:37:08] a...@php.net

Debugging the snapshot ra18cede the backtrace is incomplete:

php5.dll!ZEND_NEW_SPEC_HANDLER(_zend_execute_data * execute_data)  Line 816 + 
0xf bytes C
0001()  
php5.dll!52bd0c2f() 

Custom compilation with PGO gives more:


php5ts.dll!ZEND_NEW_SPEC_HANDLER(_zend_execute_data * execute_data, void * * * 
tsrm_ls)  Line 816 + 0x12 bytes  C
php5ts.dll!execute(_zend_op_array * op_array, void * * * tsrm_ls)  Line 410 + 
0xb bytes C
php5ts.dll!zend_execute_scripts(int type, void * * * tsrm_ls, _zval_struct * * 
retval, int file_count, ...)  Line 1280  C
php5ts.dll!php_execute_script(_zend_file_handle * primary_file, void * * * 
tsrm_ls)  Line 2473 + 0x12 bytes C
php.exe!do_cli(int argc, char * * argv, void * * * tsrm_ls)  Line 989   C
php.exe!main(int argc, char * * argv)  Line 1361 + 0x14 bytes   C
php.exe!__tmainCRTStartup()  Line 582 + 0x17 bytes  C
kernel32.dll!7603ed6c()
[Frames below may be incorrect and/or missing, no symbols loaded for 
kernel32.dll]  
ntdll.dll!77b7377b()
ntdll.dll!77b7374e()


[2012-06-15 15:53:49] a...@php.net

the patch was updated to exlude zend_disable_class only from optimization


[2012-06-15 15:52:55] a...@php.net

The following patch has been added/updated:

Patch Name: 62313.patch
Revision:   1339775574
URL:
https://bugs.php.net/patch-display.php?bug=62313&patch=62313.patch&revision=1339775574


[2012-06-15 10:38:28] paj...@php.net

Disable optimization for the new handler is going to kill many perf 
improvements 
in 5.4+.
 
I am sure the issue occurs later on, inside the error management or the ini 
fetching code. But I cannot let this patch in as it is now, disabling 
optimization 
for new is no-no :)


[2012-06-15 09:39:27] a...@php.net

The fail seems to be caused only in builds using PGO, the patch disables it for 
the relevant place.




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

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


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


Bug #53976 [Com]: running phpunit causes seg fault in php garbage collection

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

 ID: 53976
 Comment by: fidian at rumkin dot com
 Reported by:matthew dot scott dot day at gmail dot com
 Summary:running phpunit causes seg fault in php garbage
 collection
 Status: Open
 Type:   Bug
 Package:Reproducible crash
 Operating System:   ubuntu 10.10
 PHP Version:5.3.5
 Block user comment: N
 Private report: N

 New Comment:

I'm using Ubuntu 12.04 with PHP 5.3.14 (from ppa:team-mayhem/ppa), xdebug 2.2.0 
(again from the ppa) and phpunit 3.6.11.  PHP from the ppa has the stock Debian 
patches in it, but applied against the newer source version.  xdebug 2.2.0 in 
the ppa is compiled with three lines commented out (a potential fix for this 
bug, but we were wrong and it should get reverted soon).  We've written our own 
coverage collection tools instead of using the one built into phpunit.

This elusive problem happens randomly across machines and will spontaneously 
stop happening every now and then.  Trying to do various things to the machine, 
like rebooting, have mixed results.  Trying to do bisects with git repos of PHP 
and xDebug have proved ineffective since I can get false passes with a version 
that just failed a dozen times in a row.

According to the backtrace, the offensive code looks like this:
root->next->prev = root->prev;

Since it's a segmentation fault, I assume that root->next isn't pointing to 
memory that is allocated to PHP (eg. NULL).  Here's part of our backtrace, in 
the hopes that it helps:


Program received signal SIGSEGV, Segmentation fault.
0x006b9440 in gc_remove_zval_from_buffer (zv=0x7fff7570)
at /build/buildd/php5-5.3.14/Zend/zend_gc.h:189
189 /build/buildd/php5-5.3.14/Zend/zend_gc.h: No such file or directory.
in /build/buildd/php5-5.3.14/Zend/zend_gc.h
(gdb) bt full
#0  0x006b9440 in gc_remove_zval_from_buffer (zv=0x7fff7570)
at /build/buildd/php5-5.3.14/Zend/zend_gc.h:189
root_buffer = 0x7497ae84
#1  0x0068d613 in _zval_ptr_dtor (zval_ptr=0x7fff7570)
at /build/buildd/php5-5.3.14/Zend/zend_execute_API.c:446
zv = 0x7fff7570
#2  0x006a9900 in zend_hash_destroy (ht=0x4a3af20)
at /build/buildd/php5-5.3.14/Zend/zend_hash.c:729
No locals.
#3  0x0069afdf in _zval_dtor_func (zvalue=0x4a33b50)
at /build/buildd/php5-5.3.14/Zend/zend_variables.c:46
No locals.
#4  0x0068d621 in _zval_ptr_dtor (zval_ptr=0x7fff7570)
at /build/buildd/php5-5.3.14/Zend/zend_variables.h:35
zv = 0x4a33b50
#5  0x006a9900 in zend_hash_destroy (ht=0x4acb800)
at /build/buildd/php5-5.3.14/Zend/zend_hash.c:729
No locals.
#6  0x0069afdf in _zval_dtor_func (zvalue=0x4acb7b0)
at /build/buildd/php5-5.3.14/Zend/zend_variables.c:46
No locals.
#7  0x0068d621 in _zval_ptr_dtor (zval_ptr=0x7fff7570)
at /build/buildd/php5-5.3.14/Zend/zend_variables.h:35
zv = 0x4acb7b0
#8  0x006a9900 in zend_hash_destroy (ht=0x4acb698)
at /build/buildd/php5-5.3.14/Zend/zend_hash.c:729
No locals.
#9  0x0069afdf in _zval_dtor_func (zvalue=0x4a402c8)
at /build/buildd/php5-5.3.14/Zend/zend_variables.c:46
No locals.

#10 0x0068d621 in _zval_ptr_dtor (zval_ptr=0x7fff7570)
at /build/buildd/php5-5.3.14/Zend/zend_variables.h:35
zv = 0x4a402c8
#11 0x006a9900 in zend_hash_destroy (ht=0x4ac9638)
at /build/buildd/php5-5.3.14/Zend/zend_hash.c:729
No locals.
#12 0x0069afdf in _zval_dtor_func (zvalue=0x4ac9890)
at /build/buildd/php5-5.3.14/Zend/zend_variables.c:46
No locals.
#13 0x0068d621 in _zval_ptr_dtor (zval_ptr=0x7fff7570)
at /build/buildd/php5-5.3.14/Zend/zend_variables.h:35
zv = 0x4ac9890
#14 0x006a9900 in zend_hash_destroy (ht=0x49484e8)
at /build/buildd/php5-5.3.14/Zend/zend_hash.c:729
No locals.
#15 0x006bd0f9 in zend_object_std_dtor (object=0x4ac9920)
at /build/buildd/php5-5.3.14/Zend/zend_objects.c:45
No locals.
#16 0x006bd119 in zend_objects_free_object_storage (object=0x4ac9920)
---Type  to continue, or q  to quit---
at /build/buildd/php5-5.3.14/Zend/zend_objects.c:126
No locals.

#17 0x006c10ff in zend_objects_store_del_ref_by_handle_ex (
handle=80060752, handlers=0x1b80775c085)
at /build/buildd/php5-5.3.14/Zend/zend_objects_API.c:220
__orig_bailout = 
__bailout = {{__jmpbuf = {4294936880, 32767, 76854688, 0, 3129251656,
  3229462939, 74648968, 0}, __mask_was_saved = 465475400,
__saved_mask = {__val = {0, 0, 4159544400, 32767, 4159542736,
32767, 7060918, 0, 0, 0, 3219008960, 3493151322, 78464592, 0,
7060918, 0
obj = 0x1f480
failure = 0
#18 0x006c1123 in zend_objects_store_del_ref (zobject=0x494b5a0)
at /build/buildd/php5-5.3.14/Zend/zend_o

Bug #62361 [Com]: SQLite3::escapeString

2012-06-27 Thread a...@php.net
Edit report at https://bugs.php.net/bug.php?id=62361&edit=1

 ID: 62361
 Comment by: a...@php.net
 Reported by:lgynove at 163 dot com
 Summary:SQLite3::escapeString
 Status: Open
 Type:   Bug
 Package:SQLite related
 Operating System:   windows xp
 PHP Version:5.3.14
 Block user comment: N
 Private report: N

 New Comment:

Ok, after digging into the subject i've found sqlite3_bind_blob() here 
http://www.sqlite.org/c3ref/bind_blob.html . This functionality fully replaces 
sqlite2's sqlite_encode_binary() in sqlite3. As I can see, it's also 
implemented and available in PHP 
http://de2.php.net/manual/de/sqlite3stmt.bindparam.php . 

It looks pretty much like if we want to have the old behaviour, we should take 
encode.c from PECL. A sticky point here - I'm not sure that the encoding 
algorithms are equivalent in both 2 and 3. So we would need also something like 
->unescapeString() to get the data back. That could be useful in some cases but 
anyway redundant in sqlite3.

What do you think?


Previous Comments:

[2012-06-27 14:41:49] a...@php.net

Ah, now I see what you mean. php_sqlite_encode_binary in the PECL code, strange 
it wasn't moved into sqlite3.


[2012-06-27 13:57:55] fel...@php.net

But we have implemented an auxiliar escaping routine to escape the binary ones, 
as pointed out by the reporter.


[2012-06-27 13:42:50] a...@php.net

That's not a php bug i'd say. We rely here on the functionality of 
http://www.sqlite.org/c3ref/mprintf.html using %q format option. And what their 
manual says

---
The %q option works like %s in that it substitutes a nul-terminated string from 
the argument list. But %q also doubles every '\'' character. %q is designed for 
use inside a string literal. By doubling each '\'' character it escapes that 
character and allows it to be inserted into the string.
---

Escaping '\'' and '\0' can be of course easily implemented. But, as sqlite3 
itself has no other string formatting options, I'd really doubt the usefulness 
and correctness of such an implementation. Furthermore, if such a data would be 
selected back from the db, some code would be needed to restore all that 
escaped '\0' bytes and whatever else.

It might make sense to use base64 or alike to insert binary data into sqlite3 i 
think.


[2012-06-24 21:05:17] fel...@php.net

In fact actually escapeString() method is not binary-safe.


[2012-06-19 05:28:29] lgynove at 163 dot com

Description:

this bug in sqlite3,not sqlite.
use picture file (*.jpg) is not work
use *.txt is work ok

if use sqlite function (sqlite_escape_string) is work ok!


Test script:
---
$db = new sqlite3(dirname(__FILE__) . '/test.sqlite');

$str = file_get_contents('d:/www/test.jpg');
echo strlen($str),"\n";
$str = $db->escapeString($str);
echo strlen($str),"\n";

$str = file_get_contents('d:/www/test.txt');
echo strlen($str),"\n";
$str = $db->escapeString($str);
echo strlen($str),"\n";

Expected result:

5000
5000
35
35

Actual result:
--
5000
4
35
35






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


Bug #46522 [Com]: Problem using new com

2012-06-27 Thread ysabelafuentes at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=46522&edit=1

 ID: 46522
 Comment by: ysabelafuentes at gmail dot com
 Reported by:dezzell at gamanetworks dot com
 Summary:Problem using new com
 Status: Open
 Type:   Bug
 Package:COM related
 Operating System:   Windows 2003 Server
 PHP Version:5.2.6
 Block user comment: N
 Private report: N

 New Comment:

Saludos! 
Como lograstes resolver el problema del new COM ("..."). Yo estoy utilizando 
crystal report 11. agradeceria.


Previous Comments:

[2008-11-08 03:23:11] dezzell at gamanetworks dot com

Description:

I'm having problems getting COM objects to work. I'm trying to get Crystal 
Reports to work with my PHP application and have been working on this for the 
past 2 days. I've done so many searches and have tried every example I have 
come across. I always get HTTP 500 server errors with PHP Fatal errors in the 
log files when trying to load COM objects.
I have PHP 5.2.6 installed on two different Windows 2003 servers, one with IIS 
6 and the other with Apache HTTP 2.2 server. PHP works great on both servers, 
but when I try to create a new com object, I get an HTTP 500 error. Below is 
some of the code that I have tried with no success.

$creport=new com("CrystalReports12.ObjectFactory.1 ") or die("cannot load cr 
com");
$o_CrApplication = $creport ->CreateObject("CrystalDesignRunTime.Application");
or
$o_CrApplication = $creport ->CreateObject("CrystalRunTime.Application");
or
$o_CrApplication = $creport ->CreateObject("CrystalRunTime.Application.12");
I have tried other com objects and get the same HTTP 500 error.
$fso = new COM("Scripting.FileSystemObject");
$f = $fso->GetFile("c:\\test.txt");

I checked my php.ini and made changes to the [com] section, but still have 
problems.
[COM]
com.allow_dcom = true
com.autoregister_typelib = true
>From the command prompt, I run php -r "new 
>COM('CrystalReports12.ObjectFactory.1')-> 
>CreateObject('CrystalRuntime.Application.12');" and do not get any errors or 
>warnings. 
I currently have Crystal Reports 12 installed and even tried to test with 
version 9, but always get the HTTP 500 error with log errors such as the 
following:
PHP Fatal error:  Uncaught exception 'com_exception' with message 
'Source: UnknownDescription: Unknown'
PHP Fatal error:  Call to undefined method com::OpenReport()
PHP Fatal error:  Uncaught exception 'com_exception' with message 'Failed to 
create COM object


I need to get this to work and can't seem to find the solution. Let me know if 
you need me to provide any additional information.

Thanks,
Dave








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


[PHP-BUG] Bug #62431 [NEW]: array_fill_keys must always return an array

2012-06-27 Thread gmblar+php at gmail dot com
From: gmblar+php at gmail dot com
Operating system: Linux
PHP version:  5.4.4
Package:  Arrays related
Bug Type: Bug
Bug description:array_fill_keys must always return an array

Description:

array_fill_keys must always return an array as described in 
http://de3.php.net/manual/en/function.array-fill-keys.php.

When call array_fill_keys with invalid arguments the function returns an
invalid 
null!

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



Bug #30471 [Com]: var_export: Nesting level too deep - recursive dependency?

2012-06-27 Thread oxygenus at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=30471&edit=1

 ID: 30471
 Comment by: oxygenus at gmail dot com
 Reported by:none at example dot com
 Summary:var_export: Nesting level too deep - recursive
 dependency?
 Status: Not a bug
 Type:   Bug
 Package:PHP options/info functions
 Operating System:   Linux
 PHP Version:5.0.2
 Assigned To:derick
 Block user comment: N
 Private report: N

 New Comment:

var_export should receive a third param with a flag to detect recursivness and 
set 
NULL [or some special value such as an instance of an object of class 
RecursiveError].


Previous Comments:

[2012-03-28 05:48:38] jodybrabec at gmail dot com

WORKAROUND:
ob_start();
var_dump($GLOBALS);
$dataDump = ob_get_clean();


[2011-03-26 15:21:12] ricki at rocker dot com

I don't believe this is a bug as the purposes of var_dump and var_export are 
entirely different:

var_dump - simply dumps a readable form 
var_export - exports valid PHP! This code is actually usable within an 
application.

var_dump therefore can "manage" the recursive nature of global by simply doing 
the following in the output
&array(15) {
["GLOBALS"]=>
*RECURSION*

var_export on the other hand clearly can't take the same approach to recursion 
if the generated PHP output is to work as intended by the application designer. 
- it can only (and should only) fail.

hope this is useful to someone.


[2010-10-28 20:49:29] hendy at soluvas dot com

This bug is VALID!

The following code works:

var_dump($GLOBALS);

Therefore the dumping algorithm is inconsistent. var_export() should just use 
the same algorithm as var_dump().


[2010-06-27 05:55:26] jdickey at seven-sigma dot com

Derick, I'd suggest that that "expected behavior" itself is a design flaw in 
the 
PHP interpreter. The solutions I can think of right off would be ugly, granted 
(special-case check for global-variable accessor to detect whether it's 
attempting 
to recurse as an effect of debug_backtrace() and, if so, throw an exception 
that 
can then be caught by d_bt); I find it really hard to believe that such a 
heavily-
used software platform with such a large, competent company and community 
behind 
it can't come up with a better solution.

Marking this bug as 'bogus' merely insults your developer customers and 
encourages 
them to go find a real language instead.


[2004-11-15 20:19:24] der...@php.net

There is no way to return a correct output in this case, so this is not a bug 
but expected behavior.




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

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


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


Bug #62430 [Opn->Csd]: PHP Windows Installer Command Line Failure

2012-06-27 Thread rickschneider17 at hotmail dot com
Edit report at https://bugs.php.net/bug.php?id=62430&edit=1

 ID: 62430
 User updated by:rickschneider17 at hotmail dot com
 Reported by:rickschneider17 at hotmail dot com
 Summary:PHP Windows Installer Command Line Failure
-Status: Open
+Status: Closed
 Type:   Bug
 Package:*General Issues
 Operating System:   Windows 2008 R2
 PHP Version:5.3.14
 Block user comment: N
 Private report: N

 New Comment:

It seems that documentation needs to be updated... passing in ext_php_gd2 
works...


Previous Comments:

[2012-06-27 14:49:35] rickschneider17 at hotmail dot com

Description:

Trying to install php5.3.14 nts with the windows installer/msi package.  
According 
to the documentation, there should be an option called ADDLOCAL which takes a 
comma seperated list of extentions... (ext_php_gd,ext_php_mysqli) and this 
fails 
with the following message in windows event log.. 
Product: PHP 5.3.14 -- The installer has encountered an unexpected error 
installing this package. This may indicate a problem with this package. The 
error 
code is 2711. The arguments are: ext_php_gd, ,

It looks like it is failing to parse out any extra extentions

Test script:
---
msiexec /i php-5.3.14-nts-Win32-VC9-x86.msi /passive 
ADDLOCAL=ext_php_gd,ext_php_mysqli

or 

msiexec /i php-5.3.14-nts-Win32-VC9-x86.msi /passive 
ADDLOCAL="ext_php_gd,ext_php_mysqli"







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


Req #9218 [Com]: can ibase_num_rows be implemented?

2012-06-27 Thread oliverhdzrangel at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=9218&edit=1

 ID: 9218
 Comment by: oliverhdzrangel at gmail dot com
 Reported by:blib at mail dot com
 Summary:can ibase_num_rows be implemented?
 Status: Closed
 Type:   Feature/Change Request
 Package:Feature/Change Request
 Operating System:   N/A
 PHP Version:4.0.4pl1
 Block user comment: N
 Private report: N

 New Comment:

>From the Firebird FAQ
--

How to get record count for any query without executing it?

Sometimes you just want to see how many records would some query produce, 
without actually fetching them all. With Firebird 2 and derived tables it's 
quite easy:

SELECT COUNT(*) FROM ( your select query );

For example:

SELECT COUNT(*) FROM ( select * from employee where emp_no > 8 );

In earlier versions (1.x) of Firebird you should either rewrite the query to 
get the record count, or create a view and do SELECT COUNT(*) from it. For 
example:

create view my_employees as select * from employee where emp_no > 8;
commit;
SELECT COUNT(*) FROM my_employees;
commit;
drop view my_employees;


Previous Comments:

[2001-02-11 17:05:01] j...@php.net

No chance. InterBase just doesn't return the number of
records in recordset, so there's no way to implement it
without actually fetching all the rows (which is not going
to happen in the extension level). You might consider
writing a wrapper in PHP and storing the results temporarily
into an array, if you can't live without this feature.


[2001-02-11 16:41:19] der...@php.net

Feature request, not a bug


[2001-02-11 16:26:11] blib at mail dot com

Is there any chance that ibase_num_rows would be implemented? Or some other 
function that will let you know number of rows returned by query.





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


[PHP-BUG] Bug #62430 [NEW]: PHP Windows Installer Command Line Failure

2012-06-27 Thread rickschneider17 at hotmail dot com
From: rickschneider17 at hotmail dot com
Operating system: Windows 2008 R2
PHP version:  5.3.14
Package:  *General Issues
Bug Type: Bug
Bug description:PHP Windows Installer Command Line Failure

Description:

Trying to install php5.3.14 nts with the windows installer/msi package. 
According 
to the documentation, there should be an option called ADDLOCAL which takes
a 
comma seperated list of extentions... (ext_php_gd,ext_php_mysqli) and this
fails 
with the following message in windows event log.. 
Product: PHP 5.3.14 -- The installer has encountered an unexpected error 
installing this package. This may indicate a problem with this package. The
error 
code is 2711. The arguments are: ext_php_gd, ,

It looks like it is failing to parse out any extra extentions

Test script:
---
msiexec /i php-5.3.14-nts-Win32-VC9-x86.msi /passive
ADDLOCAL=ext_php_gd,ext_php_mysqli

or 

msiexec /i php-5.3.14-nts-Win32-VC9-x86.msi /passive
ADDLOCAL="ext_php_gd,ext_php_mysqli"


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



Bug #62361 [Com]: SQLite3::escapeString

2012-06-27 Thread a...@php.net
Edit report at https://bugs.php.net/bug.php?id=62361&edit=1

 ID: 62361
 Comment by: a...@php.net
 Reported by:lgynove at 163 dot com
 Summary:SQLite3::escapeString
 Status: Open
 Type:   Bug
 Package:SQLite related
 Operating System:   windows xp
 PHP Version:5.3.14
 Block user comment: N
 Private report: N

 New Comment:

Ah, now I see what you mean. php_sqlite_encode_binary in the PECL code, strange 
it wasn't moved into sqlite3.


Previous Comments:

[2012-06-27 13:57:55] fel...@php.net

But we have implemented an auxiliar escaping routine to escape the binary ones, 
as pointed out by the reporter.


[2012-06-27 13:42:50] a...@php.net

That's not a php bug i'd say. We rely here on the functionality of 
http://www.sqlite.org/c3ref/mprintf.html using %q format option. And what their 
manual says

---
The %q option works like %s in that it substitutes a nul-terminated string from 
the argument list. But %q also doubles every '\'' character. %q is designed for 
use inside a string literal. By doubling each '\'' character it escapes that 
character and allows it to be inserted into the string.
---

Escaping '\'' and '\0' can be of course easily implemented. But, as sqlite3 
itself has no other string formatting options, I'd really doubt the usefulness 
and correctness of such an implementation. Furthermore, if such a data would be 
selected back from the db, some code would be needed to restore all that 
escaped '\0' bytes and whatever else.

It might make sense to use base64 or alike to insert binary data into sqlite3 i 
think.


[2012-06-24 21:05:17] fel...@php.net

In fact actually escapeString() method is not binary-safe.


[2012-06-19 05:28:29] lgynove at 163 dot com

Description:

this bug in sqlite3,not sqlite.
use picture file (*.jpg) is not work
use *.txt is work ok

if use sqlite function (sqlite_escape_string) is work ok!


Test script:
---
$db = new sqlite3(dirname(__FILE__) . '/test.sqlite');

$str = file_get_contents('d:/www/test.jpg');
echo strlen($str),"\n";
$str = $db->escapeString($str);
echo strlen($str),"\n";

$str = file_get_contents('d:/www/test.txt');
echo strlen($str),"\n";
$str = $db->escapeString($str);
echo strlen($str),"\n";

Expected result:

5000
5000
35
35

Actual result:
--
5000
4
35
35






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


Bug #62361 [Ver->Opn]: SQLite3::escapeString

2012-06-27 Thread felipe
Edit report at https://bugs.php.net/bug.php?id=62361&edit=1

 ID: 62361
 Updated by: fel...@php.net
 Reported by:lgynove at 163 dot com
 Summary:SQLite3::escapeString
-Status: Verified
+Status: Open
 Type:   Bug
 Package:SQLite related
 Operating System:   windows xp
 PHP Version:5.3.14
 Block user comment: N
 Private report: N

 New Comment:

But we have implemented an auxiliar escaping routine to escape the binary ones, 
as pointed out by the reporter.


Previous Comments:

[2012-06-27 13:42:50] a...@php.net

That's not a php bug i'd say. We rely here on the functionality of 
http://www.sqlite.org/c3ref/mprintf.html using %q format option. And what their 
manual says

---
The %q option works like %s in that it substitutes a nul-terminated string from 
the argument list. But %q also doubles every '\'' character. %q is designed for 
use inside a string literal. By doubling each '\'' character it escapes that 
character and allows it to be inserted into the string.
---

Escaping '\'' and '\0' can be of course easily implemented. But, as sqlite3 
itself has no other string formatting options, I'd really doubt the usefulness 
and correctness of such an implementation. Furthermore, if such a data would be 
selected back from the db, some code would be needed to restore all that 
escaped '\0' bytes and whatever else.

It might make sense to use base64 or alike to insert binary data into sqlite3 i 
think.


[2012-06-24 21:05:17] fel...@php.net

In fact actually escapeString() method is not binary-safe.


[2012-06-19 05:28:29] lgynove at 163 dot com

Description:

this bug in sqlite3,not sqlite.
use picture file (*.jpg) is not work
use *.txt is work ok

if use sqlite function (sqlite_escape_string) is work ok!


Test script:
---
$db = new sqlite3(dirname(__FILE__) . '/test.sqlite');

$str = file_get_contents('d:/www/test.jpg');
echo strlen($str),"\n";
$str = $db->escapeString($str);
echo strlen($str),"\n";

$str = file_get_contents('d:/www/test.txt');
echo strlen($str),"\n";
$str = $db->escapeString($str);
echo strlen($str),"\n";

Expected result:

5000
5000
35
35

Actual result:
--
5000
4
35
35






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


Bug #62361 [Com]: SQLite3::escapeString

2012-06-27 Thread a...@php.net
Edit report at https://bugs.php.net/bug.php?id=62361&edit=1

 ID: 62361
 Comment by: a...@php.net
 Reported by:lgynove at 163 dot com
 Summary:SQLite3::escapeString
 Status: Verified
 Type:   Bug
 Package:SQLite related
 Operating System:   windows xp
 PHP Version:5.3.14
 Block user comment: N
 Private report: N

 New Comment:

That's not a php bug i'd say. We rely here on the functionality of 
http://www.sqlite.org/c3ref/mprintf.html using %q format option. And what their 
manual says

---
The %q option works like %s in that it substitutes a nul-terminated string from 
the argument list. But %q also doubles every '\'' character. %q is designed for 
use inside a string literal. By doubling each '\'' character it escapes that 
character and allows it to be inserted into the string.
---

Escaping '\'' and '\0' can be of course easily implemented. But, as sqlite3 
itself has no other string formatting options, I'd really doubt the usefulness 
and correctness of such an implementation. Furthermore, if such a data would be 
selected back from the db, some code would be needed to restore all that 
escaped '\0' bytes and whatever else.

It might make sense to use base64 or alike to insert binary data into sqlite3 i 
think.


Previous Comments:

[2012-06-24 21:05:17] fel...@php.net

In fact actually escapeString() method is not binary-safe.


[2012-06-19 05:28:29] lgynove at 163 dot com

Description:

this bug in sqlite3,not sqlite.
use picture file (*.jpg) is not work
use *.txt is work ok

if use sqlite function (sqlite_escape_string) is work ok!


Test script:
---
$db = new sqlite3(dirname(__FILE__) . '/test.sqlite');

$str = file_get_contents('d:/www/test.jpg');
echo strlen($str),"\n";
$str = $db->escapeString($str);
echo strlen($str),"\n";

$str = file_get_contents('d:/www/test.txt');
echo strlen($str),"\n";
$str = $db->escapeString($str);
echo strlen($str),"\n";

Expected result:

5000
5000
35
35

Actual result:
--
5000
4
35
35






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


Bug #62427 [Opn->Nab]: PCRE invalid "\k" sequence does not cause warning or error

2012-06-27 Thread felipe
Edit report at https://bugs.php.net/bug.php?id=62427&edit=1

 ID: 62427
 Updated by: fel...@php.net
 Reported by:danielklein at airpost dot net
 Summary:PCRE invalid "\k" sequence does not cause warning or
 error
-Status: Open
+Status: Not a bug
 Type:   Bug
 Package:PCRE related
 PHP Version:5.4.4
 Block user comment: N
 Private report: N

 New Comment:

Not a PHP bug. The error depends on the PCRE library version.

$ pcretest 
PCRE version 8.02 2010-03-19

  re> /\k/
data> a
No match
  re> /\g/
Failed: a numbered reference must not be zero at offset 1


Previous Comments:

[2012-06-27 03:13:13] ras...@php.net

For reference, the command pcretest tool that comes with PCRE-8.30 gives this:

  re> /\k/
Failed: \k is not followed by a braced, angle-bracketed, or quoted name at 
offset 
2
  re> /\g/
Failed: a numbered reference must not be zero at offset 1


[2012-06-27 01:22:24] danielklein at airpost dot net

Description:

The "\k" escape must be followed by 'name',  or {name}. A PCRE regex that 
contains "\k" without the properly quoted name will compile without an error 
and will always fail as "\k" can never (as far as I know) match anything in the 
subject string. It is almost identical to "\g", except "\g" also allows "\gn", 
"\g{n}" or "\g{-n}" where "n" is any positive decimal number.

I have been unable to test PCRE directly (i.e. via the command line, not 
through PHP) as I can't compile it on my computer. I have looked through the 
source code and the test results, and from that it seems to be working 
correctly. Although I'm not 100% sure, I think this bug is specific to PHP.

Test script:
---


Expected result:

Warning: preg_match(): Compilation failed: **something about name missing in \k 
back-reference** at offset 1 in test.php on line 3
 bool(false)
Warning: preg_match(): Compilation failed: a numbered reference must not be 
zero at offset 1 in test.php on line 3
 bool(false)

Actual result:
--
int(0) 
Warning: preg_match(): Compilation failed: a numbered reference must not be 
zero at offset 1 in test.php on line 3
 bool(false)






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


Bug #48614 [Com]: Loading "pdo_sqlite.so" fails: undefined symbol: sqlite3_libversion

2012-06-27 Thread rs at bytecamp dot net
Edit report at https://bugs.php.net/bug.php?id=48614&edit=1

 ID: 48614
 Comment by: rs at bytecamp dot net
 Reported by:kaspernj at gmail dot com
 Summary:Loading "pdo_sqlite.so" fails: undefined symbol:
 sqlite3_libversion
 Status: Assigned
 Type:   Bug
 Package:PDO related
 Operating System:   Ubuntu Jaunty
 PHP Version:5.3.0RC4
 Assigned To:scottmac
 Block user comment: N
 Private report: N

 New Comment:

This bug still exists in PHP-5.4.4.
When will it ever be fixed?


Previous Comments:

[2012-06-13 02:43:34] kris dot glynn at virginaustralia dot com

I've just ran into this exact issue compiling php-5.3.13

I used..

--without-sqlite --with-sqlite3=shared --with-pdo-sqlite=shared

.. which still produced the "undefined symbol: sqlite3_libversion" error.

It wasn't until I tried the patch above to configure script from "jd at cpanel 
dot net" that the error goes away.

My question is why are we still having to do this with php-5.3.13 ? Am I 
missing something ?

My exact configure options are below..

./configure  --with-apxs2=/data/www2/apache/bin/apxs --prefix=/data/www2/apache 
--with-config-file-path=/data/www2/apache/php --with-openssl=/data/www2/apache 
--with-curl=/data/www2/apache --with-gd --enable-gd-native-ttf 
--with-png-dir=/data/www2/apache --with-jpeg-dir=/data/www2/apache 
--with-freetype-dir=/data/www2/apache --with-xpm-dir=/usr/X11R6/ 
--with-zlib-dir=/data/www2/apache 
--with-oci8=instantclient,/usr/lib/oracle/10.2.0.4/client/lib 
--with-libxml-dir=/data/www2/apache --with-mysql=/data/www2/apache 
--with-ldap=/data/www2/apache --with-pear=$BASE_PATH/pear/ --enable-pdo=shared 
--without-sqlite --with-sqlite3=shared --with-pdo-sqlite=shared 
--with-pdo-oci=shared,instantclient,/usr,10.2.0.4 
--with-pdo-mysql=shared,/data/www2/apache --with-mcrypt=/data/www2/apache

(all the dependencies for php as you can see above exist in /data/www2/apache)


[2010-10-14 19:21:32] jd at cpanel dot net

The problem is that pdo_sqlite compiles against the embedded copy of sqlite3 
but doesn't include the sqlite3 object files in the final pdo_sqlite.so.

Ugly patch directly against the configure script:

--- php-5.3.3.orig/configure2010-07-21 05:53:06.0 -0500
+++ php-5.3.3/configure 2010-10-14 09:40:17.0 -0500
@@ -75183,6 +75183,12 @@
 
   else
   # use bundled libs
+
+  # This change is anchored here to avoid patch being misapplied.  This 
really only needs to be added
+  # when pdo_sqlite is compiled shared and using the bundled sqlite3.  It 
shouldn't hurt so long as the
+  # bundled sqlite3 is used though.
+  shared_objects_pdo_sqlite="$shared_objects_pdo_sqlite 
ext/sqlite3/libsqlite/sqlite3.lo"
+
   if test "$enable_maintainer_zts" = "yes"; then
 threadsafe_flags="-DSQLITE_THREADSAFE=1"
   else


[2010-06-08 12:52:20] kontakt at beberlei dot de

You can get this working with the following configure:

--without-sqlite --with-sqlite3=shared --with-pdo-sqlite=shared,/usr

More information in this thread: http://news.php.net/php.pdo/427


[2010-05-25 23:50:30] ashoat at gmail dot com

The problem is still occurring. There really ought to be a patch by now.


[2010-04-25 13:00:18] ovidio dot balan at gmail dot com

lol .. :(




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

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


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


Bug #62381 [Opn]: FPM doesn't handle Apache script_filename on Windows

2012-06-27 Thread dave at yougeezer dot co dot uk
Edit report at https://bugs.php.net/bug.php?id=62381&edit=1

 ID: 62381
 User updated by:dave at yougeezer dot co dot uk
 Reported by:dave at yougeezer dot co dot uk
 Summary:FPM doesn't handle Apache script_filename on Windows
 Status: Open
 Type:   Bug
 Package:CGI/CLI related
 Operating System:   Windows XP
 PHP Version:5.4.4
 Block user comment: N
 Private report: N

 New Comment:

Ah, thanks for clearing that up.  That explains the fact that there aren't any 
extra php processes being launched.  Doesn't explain the issue with no input 
file 
being specified as I'd have though #54152 would have fixed the path issue of 
Apache not passing SCRIPT_FILENAME correctly.

Shame about libevent holding FPM back on Windows, maybe the work being done 
with 
libuv could be of use?


Previous Comments:

[2012-06-27 10:10:19] a...@php.net

You use c:\php54\php-cgi.exe which runs clearly in FastCGI mode. No FPM is 
going under Win as it uses libevent (saw some people playing with cygwin, but 
that's tricky stuff anyway). This looks more like a configuration issue in your 
apache after all.


[2012-06-21 12:56:55] dave at yougeezer dot co dot uk

There seems to be, I have FPM working fine with the nginx Windows port and PHP 
5.4.4.

Here's an example of the config I used for nginx:
location ~ \.php$ {
  root   html;
  fastcgi_pass   127.0.0.1:9054;
  fastcgi_index  index.php;
  fastcgi_param  SCRIPT_FILENAME  c:/nginx-1.2.1/html/$fastcgi_script_name;
  includefastcgi_params;
}

Plus the "-b IP:Port" argument is there... but I didn't see any new php-cgi 
processes created to handle requests.


[2012-06-21 12:41:57] paj...@php.net

There is no FPM on windows.


[2012-06-21 09:55:14] dave at yougeezer dot co dot uk

Description:

When running PHP using the FPM support, it doesn't appear to process the 
script_filename environmental variable passed by Apache (using mod_proxy_fcgi). 
 
This is probably related to #54152

Running a tool that monitors file access the following path is checked:

C:\php54\proxy:fcgi:\127.0.0.1:9054\c:\Apache24\htdocs\

Don't fully understand how PHP handles this but tried setting 
APACHE_PROXY_FCGI_PREFIX to various different values by using:
SetEnv APACHE_PROXY_FCGI_PREFIX "proxy:fcgi:\\"
...in the Apache configuration file.  But it didn't appear to have any effect.

Test script:
---
Apache conf:
ProxyPass / fcgi://127.0.0.1:9054/c:/Apache24/htdocs/php54

PHP startup:
c:\php54\php-cgi.exe -b 127.0.0.1:9054 -c c:\php54\php.ini

Expected result:

c:\Apache24\htdocs\

Actual result:
--
C:\php54\proxy:fcgi:\127.0.0.1:9054\c:\Apache24\htdocs\






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


Bug #62381 [Com]: FPM doesn't handle Apache script_filename on Windows

2012-06-27 Thread a...@php.net
Edit report at https://bugs.php.net/bug.php?id=62381&edit=1

 ID: 62381
 Comment by: a...@php.net
 Reported by:dave at yougeezer dot co dot uk
 Summary:FPM doesn't handle Apache script_filename on Windows
 Status: Open
 Type:   Bug
 Package:CGI/CLI related
 Operating System:   Windows XP
 PHP Version:5.4.4
 Block user comment: N
 Private report: N

 New Comment:

You use c:\php54\php-cgi.exe which runs clearly in FastCGI mode. No FPM is 
going under Win as it uses libevent (saw some people playing with cygwin, but 
that's tricky stuff anyway). This looks more like a configuration issue in your 
apache after all.


Previous Comments:

[2012-06-21 12:56:55] dave at yougeezer dot co dot uk

There seems to be, I have FPM working fine with the nginx Windows port and PHP 
5.4.4.

Here's an example of the config I used for nginx:
location ~ \.php$ {
  root   html;
  fastcgi_pass   127.0.0.1:9054;
  fastcgi_index  index.php;
  fastcgi_param  SCRIPT_FILENAME  c:/nginx-1.2.1/html/$fastcgi_script_name;
  includefastcgi_params;
}

Plus the "-b IP:Port" argument is there... but I didn't see any new php-cgi 
processes created to handle requests.


[2012-06-21 12:41:57] paj...@php.net

There is no FPM on windows.


[2012-06-21 09:55:14] dave at yougeezer dot co dot uk

Description:

When running PHP using the FPM support, it doesn't appear to process the 
script_filename environmental variable passed by Apache (using mod_proxy_fcgi). 
 
This is probably related to #54152

Running a tool that monitors file access the following path is checked:

C:\php54\proxy:fcgi:\127.0.0.1:9054\c:\Apache24\htdocs\

Don't fully understand how PHP handles this but tried setting 
APACHE_PROXY_FCGI_PREFIX to various different values by using:
SetEnv APACHE_PROXY_FCGI_PREFIX "proxy:fcgi:\\"
...in the Apache configuration file.  But it didn't appear to have any effect.

Test script:
---
Apache conf:
ProxyPass / fcgi://127.0.0.1:9054/c:/Apache24/htdocs/php54

PHP startup:
c:\php54\php-cgi.exe -b 127.0.0.1:9054 -c c:\php54\php.ini

Expected result:

c:\Apache24\htdocs\

Actual result:
--
C:\php54\proxy:fcgi:\127.0.0.1:9054\c:\Apache24\htdocs\






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


Bug #1003 [Com]: false to compile gd.c missing gdfontt.h (GD-1.3)

2012-06-27 Thread billhansachim at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=1003&edit=1

 ID: 1003
 Comment by: billhansachim at gmail dot com
 Reported by:hle at sjmercury dot com
 Summary:false to compile gd.c missing gdfontt.h (GD-1.3)
 Status: Closed
 Type:   Bug
 Package:Compile Failure
 Operating System:   SPARC solaris 2.6
 PHP Version:3.0.5
 Block user comment: N
 Private report: N

 New Comment:

* SQL-Injection
- Verhinderung:
- Mit PDO binden
- Datenbanknutzer nur limitierte Rechte (NIE root nutzer!)
- Beispiel:
- Erwarteter Aufruf: http://webserver/cgi-bin/find.cgi?ID=42
- SQL-Injektion: http://webserver/cgi-bin/find.cgi?
ID=42;UPDATE+USER+SET+TYPE='admin'+WHERE+ID=23

* Benutzerkennung
- Sorgsam mit umgehen
- Schema wie Vorname.Nachname vermeiden
- Keine E-Mail Adressen

* Enumerationsangriff
- Erkennungsmerkmale:
- Viele zugriffe von der gleichen IP
- Zugriffszahlen überschreiten bestimmte Anzahl (Script!)
- Zugriffsparameter werden nach einem regelmäßigen Muster variiert
- Abwehrmaßnahmen:
- Captcha 
- Zeitverzögerung des Zugriffs (exponentielle zeitsteigerung)

* Benutzer Authentifizierung
- mittels HTTP-Protokoll über Webserver (Liste mit User/PW)
- per PHP-Skript ($_SERVER['PHP_AUTH_USER'],...)
- per HTML-Formular und PHP-Skript mit PW/ID Feld

* SSL
- Ziele:
- Vertraulichkeit
- Integrität
- Authentifizierung
- Gültigkeit des Zertifikat:
- Zertifikat muss von Zertifizierungsstelle validiert werden
- Ablauflaufdatum 

* Eigenschaften von Webanwendungen
- Plattformunabhängig
- On the Fly and need deployment
- Lebenslange Entwicklung
- Ererignisgesteuerter Client

* Ebenenmodell Sicherheitskonzept
0. Netzwerk/Host (absicherung des netzwerks/host)
1. System (absicherung der systemsoftware)
2. Technologie (richtige wahl der technologie(https/http))
3. Implementierung (keine programmierfehler(sql-inj.))
4. Logik (absicherung von prozessen(sichere pw erzwingen))
5. Semantik (täuschungsschutz (phishing schutz))

* Informations-Bekanntgabe verhindern
- Keine Kommentare in Code

* Vorteile von Sessions:
-   Aufwendig errechnete Daten speichern
-   Benutzerführung über bestimmte Reihenfolgen
-   Zwischenspeichern von Daten, bevor sie in die Datenbank kommen 
(Warenkorb)

* Nachteile von Sessions:
-   Verteilung von Serverlast mit Sessions erschwert
-   Server merkt nicht, ob eine Session beendet ist
-   Lesezeichen von Seiten mit Sessions kˆnnen Probleme bringen

* Session diebstahl nur durch raten möglich

* Sessions sinnvoll absichern:
- Zusätzliche IP/ID
- Keine kritischen Infos in Sessions sichern

* Erkennen von Manipulation 
- Zu viele oder zu wenige Form-Variablen
- Falsche Übertragung (GET statt POST)
- Session ID kein Standard

* Reaktion auf Manipulation
Sollte: 
- Verarbeitung abbrechen aber korrekte verarbeitung vortäuschen
- Explizite Warnung ausgeben
- Weiterleitung auf Fehlerseite
Nicht:
- Dienst einstellen
- Ungefilterte Fehlermeldung
- "Wegen Wartungsarbeiten nicht verfügbar"


Previous Comments:

[2012-06-27 08:39:23] unused dot spambox at gmail dot com


http://www.w3.org/1999/XSL/Transform";>


0








.   
 



right

jop.reisen {background-color: 
green;}









 











 
 






 
 






 
 


   


 





 EUR
( 
Dollar) 
 

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

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

 ID: 1
 Updated by: larue...@php.net
 Reported by:rasmus at lerdorf dot on dot ca
 Summary:Apache 1.3b3 + mod_php3 is slow
 Status: Not a bug
 Type:   Bug
 Package:*General Issues
 Operating System:   Solaris 2.5.1
 PHP Version:3.0b3
 Block user comment: Y
 Private report: N

 New Comment:

testing what? :)


Previous Comments:

[2012-05-30 22:23:14] nico...@php.net

Automatic comment from SVN on behalf of nicolas
Revision: http://svn.php.net/viewvc/?view=revision&revision=325902
Log: Fix github issue #1, Ref. https://github.com/orieg/php-judy/issues/1


[2011-11-11 14:43:58] se...@php.net

Automatic comment from SVN on behalf of seros
Revision: http://svn.php.net/viewvc/?view=revision&revision=319056
Log: Example #1 was wrong


[2011-03-25 09:52:21] der...@php.net

testiung


[2011-03-23 17:08:32] z...@php.net

test


[2011-01-06 02:41:39] ahar...@php.net

Automatic comment from SVN on behalf of aharvey
Revision: http://svn.php.net/viewvc/?view=revision&revision=307144
Log: Fix doc bug #53660 (There is an error in the code provided in Example #1).




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

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


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


Bug #1003 [Com]: false to compile gd.c missing gdfontt.h (GD-1.3)

2012-06-27 Thread unused dot spambox at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=1003&edit=1

 ID: 1003
 Comment by: unused dot spambox at gmail dot com
 Reported by:hle at sjmercury dot com
 Summary:false to compile gd.c missing gdfontt.h (GD-1.3)
 Status: Closed
 Type:   Bug
 Package:Compile Failure
 Operating System:   SPARC solaris 2.6
 PHP Version:3.0.5
 Block user comment: N
 Private report: N

 New Comment:


http://www.w3.org/1999/XSL/Transform";>


0








.   
 



right

jop.reisen {background-color: 
green;}









 











 
 






 
 






 
 


   


 





 EUR
( 
Dollar) 


 EUR






Von  nach 


Von  nach 









 - 
Dauer:  
(,  )







 
() 


von  nach  
Klassen: 





Wetter


Durchschnitt




C




 F


 






Aktien







Name: 
Mittelwert:  








Previous Comments:

[1998-12-23 18:15:28] rasmus

Huh?  The various font header files are part of the GD package.


[1998-12-23 17:26:51] hle at sjmercury dot com







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


Bug #60825 [Com]: Segfault when running symfony 2 tests

2012-06-27 Thread maxime dot marais at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=60825&edit=1

 ID: 60825
 Comment by: maxime dot marais at gmail dot com
 Reported by:php at wallbash dot com
 Summary:Segfault when running symfony 2 tests
 Status: Assigned
 Type:   Bug
 Package:Reproducible crash
 Operating System:   Ubuntu 10.04.3 LTS
 PHP Version:5.4.0RC6
 Assigned To:laruence
 Block user comment: N
 Private report: N

 New Comment:

It seems this issue is solved with version 5.3.14 (http://bugs.php.net/61730). 
For my project, version 5.3.14 solved the issue that still occured with version 
5.3.13.

Could someone confirm?


Previous Comments:

[2012-05-31 02:16:28] larue...@php.net

@maxime dot marais at gmail dot com, okey, I will write to your mail. thanks


[2012-05-30 14:12:23] maxime dot marais at gmail dot com

Laruence,

I am unable to recreate a simple script that would trigger the segmentation 
fault I'm facing. It seems many objects have to be handled before the 
segmentation fault occurs. For example, a test script runs well with phpunit if 
ran once, but fails if ran twice or more (phpunit with --repeat N option, N > 
1). I can not neither provide my source code right here on the forum as the 
project I'm working on is not public. Anyway, I guess there would too much 
files 
to provide and the project would be complicated to reassemble.

However, if you accept, I suggest to send you the current code + necessary data 
and test files by private mail if you engage not to distribute this code nor 
keep any copy of it once the bug fixed. 

Please, contact me by mail.


[2012-05-23 07:33:08] php at wallbash dot com

- DUMP #3 -


$ gdb --args php /usr/local/bin/phpunit --coverage-text=cover.txt 
test/InstanciationTest.php 
GNU gdb (GDB) CentOS (7.0.1-42.el5.centos)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later 
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
...
Reading symbols from /usr/bin/php...(no debugging symbols found)...done.
(gdb) r
Starting program: /usr/bin/php /usr/local/bin/phpunit --coverage-text=cover.txt 
test/InstanciationTest.php
[Thread debugging using libthread_db enabled]
PHPUnit 3.6.10 by Sebastian Bergmann.

.

Time: 4 seconds, Memory: 21.00Mb

OK (13 tests, 71 assertions)

Generating textual code coverage report, this may take a moment.
Program received signal SIGSEGV, Segmentation fault.
0x00652700 in ?? ()
(gdb) bt
#0  0x00652700 in ?? ()
#1  0x2aaab16abe4c in ?? () from /usr/lib64/php/modules/pdo.so
#2  0x00692bcd in ?? ()
#3  0x0065876b in execute ()
#4  0x2f570f4f in xdebug_execute (op_array=0x2aaab428c878) at 
/tmp/pear/install/xdebug/xdebug.c:1390
#5  0x0065915d in ?? ()
#6  0x0065876b in execute ()
#7  0x2f570f4f in xdebug_execute (op_array=0x179f520) at 
/tmp/pear/install/xdebug/xdebug.c:1390
#8  0x0065915d in ?? ()
#9  0x0065876b in execute ()
#10 0x2f570f4f in xdebug_execute (op_array=0x1513890) at 
/tmp/pear/install/xdebug/xdebug.c:1390
#11 0x0065915d in ?? ()
#12 0x0065876b in execute ()
#13 0x2f570f4f in xdebug_execute (op_array=0x1986ea8) at 
/tmp/pear/install/xdebug/xdebug.c:1390
#14 0x00627043 in zend_call_function ()
#15 0x0064830f in zend_call_method ()
#16 0x006507e8 in zend_objects_destroy_object ()
#17 0x0064ea3c in gc_collect_cycles ()
#18 0x0064f00e in gc_zval_possible_root ()
#19 0x006b9031 in ?? ()
#20 0x0065876b in execute ()
#21 0x2f570f4f in xdebug_execute (op_array=0x21dedc0) at 
/tmp/pear/install/xdebug/xdebug.c:1390
#22 0x0065915d in ?? ()
#23 0x0065876b in execute ()
#24 0x2f570f4f in xdebug_execute (op_array=0x21de378) at 
/tmp/pear/install/xdebug/xdebug.c:1390
#25 0x0065915d in ?? ()
#26 0x0065876b in execute ()
#27 0x2f570f4f in xdebug_execute (op_array=0x21b9718) at 
/tmp/pear/install/xdebug/xdebug.c:1390
#28 0x0065915d in ?? ()
#29 0x0065876b in execute ()
#30 0x2f570f4f in xdebug_execute (op_array=0x2ac245b0) at 
/tmp/pear/install/xdebug/xdebug.c:1390
#31 0x0065915d in ?? ()
#32 0x0065876b in execute ()
#33 0x2f570f4f in xdebug_execute (op_array=0x2086cd0) at 
/tmp/pear/install/xdebug/xdebug.c:1390
#34 0x00659

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

2012-06-27 Thread billhansachim at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=1&edit=1

 ID: 1
 Comment by: billhansachim at gmail dot com
 Reported by:rasmus at lerdorf dot on dot ca
 Summary:Apache 1.3b3 + mod_php3 is slow
 Status: Not a bug
 Type:   Bug
 Package:*General Issues
 Operating System:   Solaris 2.5.1
 PHP Version:3.0b3
 Block user comment: N
 Private report: N

 New Comment:


http://www.w3.org/1999/XSL/Transform";>


0








.   
 



right

jop.reisen {background-color: 
green;}









 











 
 






 
 






 
 


   


 





 EUR
( 
Dollar) 


 EUR






Von  nach 


Von  nach 









 - 
Dauer:  
(,  )







 
() 


von  nach  
Klassen: 





Wetter


Durchschnitt




C




 F


 






Aktien







Name: 
Mittelwert:  








Previous Comments:

[2012-05-30 22:23:14] nico...@php.net

Automatic comment from SVN on behalf of nicolas
Revision: http://svn.php.net/viewvc/?view=revision&revision=325902
Log: Fix github issue #1, Ref. https://github.com/orieg/php-judy/issues/1


[2011-11-11 14:43:58] se...@php.net

Automatic comment from SVN on behalf of seros
Revision: http://svn.php.net/viewvc/?view=revision&revision=319056
Log: Example #1 was wrong


[2011-03-25 09:52:21] der...@php.net

testiung


[2011-03-23 17:08:32] z...@php.net

test


[2011-01-06 02:41:39] ahar...@php.net

Automatic comment from SVN on behalf of aharvey
Revision: http://svn.php.net/viewvc/?view=revision&revision=307144
Log: Fix doc bug #53660 (There is an error in the code provided in Example #1).




The remainder of the comments for this report are too long. To view
the