Bug #63785 [Opn->Fbk]: php-fpm segfault

2012-12-16 Thread aharvey
Edit report at https://bugs.php.net/bug.php?id=63785&edit=1

 ID: 63785
 Updated by: ahar...@php.net
 Reported by:lys0212 at qq dot com
 Summary:php-fpm segfault
-Status: Open
+Status: Feedback
 Type:   Bug
 Package:FPM related
 Operating System:   RHEL6.3
 PHP Version:5.3.19
 Block user comment: N
 Private report: N

 New Comment:

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

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

Specifically, we're going to need a backtrace with debug information, I think.


Previous Comments:

[2012-12-17 06:14:02] lys0212 at qq dot com

Description:

Recently, the new a server used to make web, configuration, software 
installation, etc. And now the production environment is the same. On-line soon 
found that /var/log/messages appear PHP-FPM segment error log

Dec 14 16:57:15 localhost kernel: php-fpm[32231]: segfault at 3701788 ip 
007e10b1 sp 7fff7c27f2c0 error 4 in php-fpm[40+a5c000]
Dec 14 16:57:16 localhost abrt[2735]: Saved core dump of pid 32231 
(/web/software/php/sbin/php-fpm) to /var/spool/abrt/ccpp-2012-12-14-16:57:15-
32231 (279961600 bytes)
Dec 14 16:57:16 localhost abrtd: Directory 'ccpp-2012-12-14-16:57:15-32231' 
creation detected
Dec 14 16:57:16 localhost abrtd: Executable '/web/software/php/sbin/php-fpm' 
doesn't belong to any package
Dec 14 16:57:16 localhost abrtd: 'post-create' on '/var/spool/abrt/ccpp-2012-12-
14-16:57:15-32231' exited with 1
Dec 14 16:57:16 localhost abrtd: Corrupted or bad directory 
/var/spool/abrt/ccpp-2012-12-14-16:57:15-32231, deleting
--
Then after punch, find this mistake occur only in a page, the page, but nothing 
special, but also in other production machine work well.
What is the cause?
The following is core dump information:

[root@localhost job]# gdb php -c core.32270 
GNU gdb (GDB) Red Hat Enterprise Linux (7.2-56.el6)
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.

warning: core file may not match specified executable file.
[New Thread 32270]
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2
Core was generated by `php-fpm: pool www
 
'.
Program terminated with signal 11, Segmentation fault.
#0  0x007e10b1 in zend_mm_free_cache ()
Missing separate debuginfos, use: debuginfo-install glibc-2.12-1.80.el6.x86_64
(gdb) bt
#0  0x007e10b1 in zend_mm_free_cache ()
#1  0x7fca780e53e8 in ?? ()
#2  0x01b5c978 in ?? ()
#3  0x007fca4f in zend_error_noreturn ()
#4  0x0002 in ?? ()
#5  0x01c1b060 in ?? ()
#6  0x007a86af in virtual_stat ()
#7  0x7fff7c27f580 in ?? ()
#8  0x6961625f6473732f in ?? ()
#9  0x2f7068702f696163 in ?? ()
#10 0x507463656a6f7270 in ?? ()
#11 0x6975626f6a2f5048 in ?? ()
#12 0x732f7070612f3456 in ?? ()
#13 0x2f626f6a2f657469 in ?? ()
#14 0x7068702e6f666e69 in ?? ()
#15 0x0070007068007000 in ?? ()
#16 0x7068702e in ?? ()
#17 0x in ?? ()
(gdb)








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


[PHP-BUG] Bug #63785 [NEW]: php-fpm segfault

2012-12-16 Thread lys0212 at qq dot com
From: lys0212 at qq dot com
Operating system: RHEL6.3
PHP version:  5.3.19
Package:  FPM related
Bug Type: Bug
Bug description:php-fpm segfault

Description:

Recently, the new a server used to make web, configuration, software 
installation, etc. And now the production environment is the same. On-line
soon 
found that /var/log/messages appear PHP-FPM segment error log

Dec 14 16:57:15 localhost kernel: php-fpm[32231]: segfault at 3701788 ip 
007e10b1 sp 7fff7c27f2c0 error 4 in php-fpm[40+a5c000]
Dec 14 16:57:16 localhost abrt[2735]: Saved core dump of pid 32231 
(/web/software/php/sbin/php-fpm) to
/var/spool/abrt/ccpp-2012-12-14-16:57:15-
32231 (279961600 bytes)
Dec 14 16:57:16 localhost abrtd: Directory 'ccpp-2012-12-14-16:57:15-32231'

creation detected
Dec 14 16:57:16 localhost abrtd: Executable
'/web/software/php/sbin/php-fpm' 
doesn't belong to any package
Dec 14 16:57:16 localhost abrtd: 'post-create' on
'/var/spool/abrt/ccpp-2012-12-
14-16:57:15-32231' exited with 1
Dec 14 16:57:16 localhost abrtd: Corrupted or bad directory 
/var/spool/abrt/ccpp-2012-12-14-16:57:15-32231, deleting
--
Then after punch, find this mistake occur only in a page, the page, but
nothing 
special, but also in other production machine work well.
What is the cause?
The following is core dump information:

[root@localhost job]# gdb php -c core.32270 
GNU gdb (GDB) Red Hat Enterprise Linux (7.2-56.el6)
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.

warning: core file may not match specified executable file.
[New Thread 32270]
Reading symbols from /lib64/ld-linux-x86-64.so.2...(no debugging symbols 
found)...done.
Loaded symbols for /lib64/ld-linux-x86-64.so.2
Core was generated by `php-fpm: pool www   
 
'.
Program terminated with signal 11, Segmentation fault.
#0  0x007e10b1 in zend_mm_free_cache ()
Missing separate debuginfos, use: debuginfo-install
glibc-2.12-1.80.el6.x86_64
(gdb) bt
#0  0x007e10b1 in zend_mm_free_cache ()
#1  0x7fca780e53e8 in ?? ()
#2  0x01b5c978 in ?? ()
#3  0x007fca4f in zend_error_noreturn ()
#4  0x0002 in ?? ()
#5  0x01c1b060 in ?? ()
#6  0x007a86af in virtual_stat ()
#7  0x7fff7c27f580 in ?? ()
#8  0x6961625f6473732f in ?? ()
#9  0x2f7068702f696163 in ?? ()
#10 0x507463656a6f7270 in ?? ()
#11 0x6975626f6a2f5048 in ?? ()
#12 0x732f7070612f3456 in ?? ()
#13 0x2f626f6a2f657469 in ?? ()
#14 0x7068702e6f666e69 in ?? ()
#15 0x0070007068007000 in ?? ()
#16 0x7068702e in ?? ()
#17 0x in ?? ()
(gdb)



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



Bug #63782 [Opn]: php.ini not loaded by php-fpm unless -c switch is used

2012-12-16 Thread infected817 at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=63782&edit=1

 ID: 63782
 User updated by:infected817 at gmail dot com
 Reported by:infected817 at gmail dot com
 Summary:php.ini not loaded by php-fpm unless -c switch is
 used
 Status: Open
 Type:   Bug
 Package:*Configuration Issues
 Operating System:   Ubuntu Desktop 12.10
 PHP Version:5.4.9
 Block user comment: N
 Private report: N

 New Comment:

Mystery solved.

I recompiled PHP with this configuration flag: --with-config-file-path=/etc/php5

Notice that before, I used --with-config-file-path=/etc/php5/

The trailing slash seems to be causing problems.

I think it would be helpful to do the following:
- Fix PHP to accept configuration folders with or without the trailing slash.

OR

- Add a note for --with-config-file-path in ./configure --help that says the 
trailing slash should be omitted.


Previous Comments:

[2012-12-17 02:52:05] larue...@php.net

make sure that  you have did "make clean" after you re-configure


[2012-12-17 02:30:29] infected817 at gmail dot com

Clarified php.ini location.


[2012-12-16 22:28:53] infected817 at gmail dot com

Hi there,

I actually made a mistake when copying the contents of the phpinfo() output as 
I had 2 virtual machines running at the time. My apologies for that.

I just checked again and these are the results:

Ubuntu Desktop 12.10
Configuration File (php.ini) Path   /etc/php5/
Loaded Configuration File   (none) 

However, there is a valid php.ini in /etc/php5 that is not being loaded.

Is there anything else/more information I can check/provide?


[2012-12-16 10:58:27] re...@php.net

It's compiled with: /etc/php5/fpm

Configuration File (php.ini) Path   */etc/php5/[fpm]*
Loaded Configuration File   (none)

but you try to load php.ini from: /etc/php5   <-- no fpm
it's different.


[2012-12-16 08:40:21] infected817 at gmail dot com

Description:

I am seeing an issue where PHP 5.4.9 I compile myself or installed via apt-get 
will not load the php.ini file even if it exists in the "Configuration File 
Path" unless I pass in a -c "/path/to/php.in" to start up PHP-FPM.

1. To reproduce, compile PHP 5.4.9 with these configuration options: 
--prefix=/usr/local/php-5.4.9 --with-config-file-path=/etc/php5/

2. Run make & make install.

3. Copy the stock php.ini-development to /etc/php5/php.ini

4. Create a phpinfo() file on the webserver.

5. Start PHP-FPM and browse to that phpinfo() file.

6. See the following result in the output:

Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   (none)

7. However, if we start PHP-FPM with the -c switch: 
./php-fpm --fpm-config /etc/php5/php-fpm.conf -c /etc/php5/php.ini

We see that php.ini is loaded:
Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   php.ini


The configuration is not loaded at all unless you explicitly pass it using the 
-c switch to php.ini. That is even though php.ini resides in the "Configuration 
File Path"

 

Expected result:

php.ini should be loaded since it is in the "Configuration File Path"

Actual result:
--
php.ini is not loaded at all, even though it exists in the "Configuration File 
Path"






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


Bug #63782 [Opn]: php.ini not loaded by php-fpm unless -c switch is used

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

 ID: 63782
 Updated by: larue...@php.net
 Reported by:infected817 at gmail dot com
 Summary:php.ini not loaded by php-fpm unless -c switch is
 used
 Status: Open
 Type:   Bug
 Package:*Configuration Issues
 Operating System:   Ubuntu Desktop 12.10
 PHP Version:5.4.9
 Block user comment: N
 Private report: N

 New Comment:

make sure that  you have did "make clean" after you re-configure


Previous Comments:

[2012-12-17 02:30:29] infected817 at gmail dot com

Clarified php.ini location.


[2012-12-16 22:28:53] infected817 at gmail dot com

Hi there,

I actually made a mistake when copying the contents of the phpinfo() output as 
I had 2 virtual machines running at the time. My apologies for that.

I just checked again and these are the results:

Ubuntu Desktop 12.10
Configuration File (php.ini) Path   /etc/php5/
Loaded Configuration File   (none) 

However, there is a valid php.ini in /etc/php5 that is not being loaded.

Is there anything else/more information I can check/provide?


[2012-12-16 10:58:27] re...@php.net

It's compiled with: /etc/php5/fpm

Configuration File (php.ini) Path   */etc/php5/[fpm]*
Loaded Configuration File   (none)

but you try to load php.ini from: /etc/php5   <-- no fpm
it's different.


[2012-12-16 08:40:21] infected817 at gmail dot com

Description:

I am seeing an issue where PHP 5.4.9 I compile myself or installed via apt-get 
will not load the php.ini file even if it exists in the "Configuration File 
Path" unless I pass in a -c "/path/to/php.in" to start up PHP-FPM.

1. To reproduce, compile PHP 5.4.9 with these configuration options: 
--prefix=/usr/local/php-5.4.9 --with-config-file-path=/etc/php5/

2. Run make & make install.

3. Copy the stock php.ini-development to /etc/php5/php.ini

4. Create a phpinfo() file on the webserver.

5. Start PHP-FPM and browse to that phpinfo() file.

6. See the following result in the output:

Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   (none)

7. However, if we start PHP-FPM with the -c switch: 
./php-fpm --fpm-config /etc/php5/php-fpm.conf -c /etc/php5/php.ini

We see that php.ini is loaded:
Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   php.ini


The configuration is not loaded at all unless you explicitly pass it using the 
-c switch to php.ini. That is even though php.ini resides in the "Configuration 
File Path"

 

Expected result:

php.ini should be loaded since it is in the "Configuration File Path"

Actual result:
--
php.ini is not loaded at all, even though it exists in the "Configuration File 
Path"






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


Bug #63782 [Fbk->Opn]: php.ini not loaded by php-fpm unless -c switch is used

2012-12-16 Thread infected817 at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=63782&edit=1

 ID: 63782
 User updated by:infected817 at gmail dot com
 Reported by:infected817 at gmail dot com
 Summary:php.ini not loaded by php-fpm unless -c switch is
 used
-Status: Feedback
+Status: Open
 Type:   Bug
 Package:*Configuration Issues
 Operating System:   Ubuntu Desktop 12.10
 PHP Version:5.4.9
 Block user comment: N
 Private report: N

 New Comment:

Clarified php.ini location.


Previous Comments:

[2012-12-16 22:28:53] infected817 at gmail dot com

Hi there,

I actually made a mistake when copying the contents of the phpinfo() output as 
I had 2 virtual machines running at the time. My apologies for that.

I just checked again and these are the results:

Ubuntu Desktop 12.10
Configuration File (php.ini) Path   /etc/php5/
Loaded Configuration File   (none) 

However, there is a valid php.ini in /etc/php5 that is not being loaded.

Is there anything else/more information I can check/provide?


[2012-12-16 10:58:27] re...@php.net

It's compiled with: /etc/php5/fpm

Configuration File (php.ini) Path   */etc/php5/[fpm]*
Loaded Configuration File   (none)

but you try to load php.ini from: /etc/php5   <-- no fpm
it's different.


[2012-12-16 08:40:21] infected817 at gmail dot com

Description:

I am seeing an issue where PHP 5.4.9 I compile myself or installed via apt-get 
will not load the php.ini file even if it exists in the "Configuration File 
Path" unless I pass in a -c "/path/to/php.in" to start up PHP-FPM.

1. To reproduce, compile PHP 5.4.9 with these configuration options: 
--prefix=/usr/local/php-5.4.9 --with-config-file-path=/etc/php5/

2. Run make & make install.

3. Copy the stock php.ini-development to /etc/php5/php.ini

4. Create a phpinfo() file on the webserver.

5. Start PHP-FPM and browse to that phpinfo() file.

6. See the following result in the output:

Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   (none)

7. However, if we start PHP-FPM with the -c switch: 
./php-fpm --fpm-config /etc/php5/php-fpm.conf -c /etc/php5/php.ini

We see that php.ini is loaded:
Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   php.ini


The configuration is not loaded at all unless you explicitly pass it using the 
-c switch to php.ini. That is even though php.ini resides in the "Configuration 
File Path"

 

Expected result:

php.ini should be loaded since it is in the "Configuration File Path"

Actual result:
--
php.ini is not loaded at all, even though it exists in the "Configuration File 
Path"






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


Bug #63777 [Fbk->Nab]: DateTime obj in Dec 2012 in Australia/South TZ reports 'CST' time zone abbrev

2012-12-16 Thread aharvey
Edit report at https://bugs.php.net/bug.php?id=63777&edit=1

 ID: 63777
 Updated by: ahar...@php.net
 Reported by:kavi at postpro dot net
 Summary:DateTime obj in Dec 2012 in Australia/South TZ
 reports 'CST' time zone abbrev
-Status: Feedback
+Status: Not a bug
 Type:   Bug
 Package:Date/time related
 Operating System:   OS X, CentOS, Debian
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

Unfortunately, as a Western Australian who's suffered through our state 
government's various flip-flops on daylight saving, I'm much more familiar with 
this than I want to be — the Olson database is technically correct here, as 
every state legislates or proclaims daylight saving time as "summer time", so 
the S part of the CST abbreviation is correct. Beyond that, I think that the 
Olson notes and related mailing list posts lay out the case for not prefixing 
the abbreviations reasonably well.

Realistically, any change to this would need to happen upstream anyway — I 
doubt we want to start patching tzdata to differ from the mainline that almost 
everyone else deploys.


Previous Comments:

[2012-12-15 04:38:26] ras...@php.net

Two things confuse me about this bug report. Surely it is summer in Australia 
right now, so why would you expect ACDT? And second, Olson has never used the 
'A' 
prefix and as far as I know most places don't. There is a long discussion on 
this 
in the Olson australasia file. I'll leave this as an exercise for the 
interested 
to look up. If you go to Google and search for "time in Adelaide" you get a CST 
time just like PHP provides.


[2012-12-15 04:17:30] s...@php.net

Testcase confirmed with 5.3, 5.4, 5.5 from git. All use Olson 2012.10


[2012-12-14 23:43:45] kavi at postpro dot net

See #50276 for a tangentially related bug about the Australian timezone 
abbreviations.


[2012-12-14 23:42:34] kavi at postpro dot net

Description:

Tried this on 5.3.3, 5.3.6 and 5.3.10, the latest available from the various OS 
vendors we have.  I have not yet successfully compiled 5.4.x to test there.

This occurs with the 2012.10 tzdata installed and verified with phpinfo().


Test script:
---
$date = new DateTime('now', new DateTimezone('Australia/South'));
echo $date->format('Y-m-d H:i:s T');

Expected result:

2012-12-15 10:10:13 ACDT

Actual result:
--
2012-12-15 10:10:13 CST






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


Bug #63766 [Nab->Opn]: sftp upload CURLOPT_URL errors with code 79 with directory path

2012-12-16 Thread aharvey
Edit report at https://bugs.php.net/bug.php?id=63766&edit=1

 ID: 63766
 Updated by: ahar...@php.net
 Reported by:mattsch at gmail dot com
 Summary:sftp upload CURLOPT_URL errors with code 79 with
 directory path
-Status: Not a bug
+Status: Open
 Type:   Bug
 Package:cURL related
 Operating System:   Gentoo
 PHP Version:5.4.9
 Block user comment: N
 Private report: N

 New Comment:

Reopened per previous comments, although I wonder if this might be a libcurl 
issue rather than a PHP one.


Previous Comments:

[2012-12-14 22:50:27] mattsch at gmail dot com

"foo" designates a file and not a directory.  Perhaps my test script should 
have been more clear by using a file extension like .txt or something.  The 
file I am trying to upload is being uploaded to a directory that already exists 
on the remote server.


[2012-12-14 22:47:01] mattsch at gmail dot com

This is a bug.  I am not trying to upload anything recursively.  I am simply 
trying to upload one file to a directory.  When I don't specify the target 
filename on the url, I expect that the target file created on the remote server 
is the same name as the filename that I am uploading.


[2012-12-14 08:39:20] paj...@php.net

CURL cannot upload directory (aka recursively). 

However it can create missing directories in a path if necessary using the 
create 
dir option.


[2012-12-14 06:55:24] mattsch at gmail dot com

Description:

When specifying a url in CURLOPT_URL with a directory path only using the sftp 
protocol, the upload will always fail with error code 79 (An unspecified error 
occurred during the SSH session).  If you change the CURLOPT_URL to be the same 
path but add a filename at the end of the directory path, the upload will 
succeed.


emerge -pv php:5.4

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R   ~] dev-lang/php-5.4.9:5.4  USE="apache2 bcmath bzip2 calendar cjk 
cli crypt ctype curl curlwrappers exif fileinfo filter ftp gd gdbm gmp hash 
iconv ipv6 json ldap mhash mysql mysqli mysqlnd nls pcntl pdo phar posix 
readline session simplexml snmp soap sockets spell sqlite ssl sysvipc threads 
tidy tokenizer truetype unicode wddx xml xmlwriter xpm xsl zip zlib -berkdb 
-cdb -cgi -debug -doc -embed -enchant -firebird -flatfile -fpm (-frontbase) 
-imap -inifile -intl -iodbc -kerberos (-kolab) -ldap-sasl -libedit -mssql 
-oci8-instant-client -odbc -pic -postgres -qdbm -recode (-selinux) -sharedmem 
(-sybase-ct) -xmlreader -xmlrpc" 0 kB

emerge -pv curl

These are the packages that would be merged, in order:

Calculating dependencies  e -  ... done!
[ebuild   R   ~] net-misc/curl-7.28.1  USE="idn ipv6 nonblocking ssh ssl 
threads -adns -kerberos -ldap -metalink -rtmp -static-libs {-test}" 
CURL_SSL="openssl -axtls -cyassl -gnutls -nss -polarssl" 0 kB


emerge -pv libssh2

These are the packages that would be merged, in order:

Calculating dependencies... done!
[ebuild   R   ~] net-libs/libssh2-1.4.3  USE="zlib -gcrypt -static-libs 
{-test}" 0 kB


curl -V
curl 7.28.1 (x86_64-pc-linux-gnu) libcurl/7.28.1 OpenSSL/1.0.0j zlib/1.2.7 
libidn/1.25 libssh2/1.4.3
Protocols: dict file ftp ftps gopher http https imap imaps pop3 pop3s rtsp scp 
sftp smtp smtps telnet tftp 
Features: AsynchDNS IDN IPv6 Largefile NTLM NTLM_WB SSL libz



Test script:
---
ftp://domain.tld:/tmp');
// prints 0
upload('sftp://domain.tld:/tmp/foo');

Expected result:

0
0


Actual result:
--
79
0






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


[PHP-BUG] Bug #63784 [NEW]: var_export() produces EOL symbols irregardless of target OS

2012-12-16 Thread hayk at mail dot ru
From: hayk at mail dot ru
Operating system: Windows XP
PHP version:  5.4.9
Package:  *General Issues
Bug Type: Bug
Bug description:var_export() produces EOL symbols irregardless of target OS

Description:

var_export() produces EOL symbols irregardless of target OS. It's always
"\n" even on Windows.

Test script:
---
 1);
echo var_export($a, true);
echo strlen(var_export($a, true));
?>

Expected result:

array (
  'a' => 1,
)23

Actual result:
--
array (
  'a' => 1,
)21

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



Bug #63782 [Com]: php.ini not loaded by php-fpm unless -c switch is used

2012-12-16 Thread infected817 at gmail dot com
Edit report at https://bugs.php.net/bug.php?id=63782&edit=1

 ID: 63782
 Comment by: infected817 at gmail dot com
 Reported by:infected817 at gmail dot com
 Summary:php.ini not loaded by php-fpm unless -c switch is
 used
 Status: Feedback
 Type:   Bug
 Package:*Configuration Issues
 Operating System:   Ubuntu Desktop 12.10
 PHP Version:5.4.9
 Block user comment: N
 Private report: N

 New Comment:

Hi there,

I actually made a mistake when copying the contents of the phpinfo() output as 
I had 2 virtual machines running at the time. My apologies for that.

I just checked again and these are the results:

Ubuntu Desktop 12.10
Configuration File (php.ini) Path   /etc/php5/
Loaded Configuration File   (none) 

However, there is a valid php.ini in /etc/php5 that is not being loaded.

Is there anything else/more information I can check/provide?


Previous Comments:

[2012-12-16 10:58:27] re...@php.net

It's compiled with: /etc/php5/fpm

Configuration File (php.ini) Path   */etc/php5/[fpm]*
Loaded Configuration File   (none)

but you try to load php.ini from: /etc/php5   <-- no fpm
it's different.


[2012-12-16 08:40:21] infected817 at gmail dot com

Description:

I am seeing an issue where PHP 5.4.9 I compile myself or installed via apt-get 
will not load the php.ini file even if it exists in the "Configuration File 
Path" unless I pass in a -c "/path/to/php.in" to start up PHP-FPM.

1. To reproduce, compile PHP 5.4.9 with these configuration options: 
--prefix=/usr/local/php-5.4.9 --with-config-file-path=/etc/php5/

2. Run make & make install.

3. Copy the stock php.ini-development to /etc/php5/php.ini

4. Create a phpinfo() file on the webserver.

5. Start PHP-FPM and browse to that phpinfo() file.

6. See the following result in the output:

Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   (none)

7. However, if we start PHP-FPM with the -c switch: 
./php-fpm --fpm-config /etc/php5/php-fpm.conf -c /etc/php5/php.ini

We see that php.ini is loaded:
Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   php.ini


The configuration is not loaded at all unless you explicitly pass it using the 
-c switch to php.ini. That is even though php.ini resides in the "Configuration 
File Path"

 

Expected result:

php.ini should be loaded since it is in the "Configuration File Path"

Actual result:
--
php.ini is not loaded at all, even though it exists in the "Configuration File 
Path"






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


Req #63743 [Opn->Csd]: New function request

2012-12-16 Thread arpad
Edit report at https://bugs.php.net/bug.php?id=63743&edit=1

 ID: 63743
 Updated by: ar...@php.net
 Reported by:jb7815 at gmail dot com
 Summary:New function request
-Status: Open
+Status: Closed
 Type:   Feature/Change Request
 Package:Unknown/Other Function
 Operating System:   All
 PHP Version:Irrelevant
-Assigned To:
+Assigned To:arpad
 Block user comment: N
 Private report: N



Previous Comments:

[2012-12-16 12:18:29] ar...@php.net

This can be done with array_merge_recursive().


[2012-12-11 17:58:22] jb7815 at gmail dot com

Description:

Suggestion:
Could you please implement a function to merge associative arrays without 
overwriting duplicate keys.

Unless there already is one that I have missed?

I have provided a small example that works to a point that will demonstrate my 
idea.

Thanks. 

Test script:
---
function array_merge_assoc($array1, $array2){   
foreach($array2 as $key => $value){
if(array_key_exists($key, $array1)){
$result[$key] = array_merge($array1[$key], 
$array2[$key]);
unset($array2[$key]);
}else{
$result[$key] = $array2[$key];
}
}
return $result;
}
$userConfig = ['libraries' => ['database', 'session', 'security']];
$defaults = ['libraries' => ['benchmark' , 'event', 'error'],
   'helpers' => ['html','date','file']];
print_r(array_merge_assoc($userConfig,$defaults));

Expected result:

Array
(
[libraries] => Array
(
[0] => database
[1] => session
[2] => security
[3] => benchmark
[4] => event
[5] => error
)

[helpers] => Array
(
[0] => html
[1] => date
[2] => file
)

)







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


Req #63743 [Com]: New function request

2012-12-16 Thread ar...@php.net
Edit report at https://bugs.php.net/bug.php?id=63743&edit=1

 ID: 63743
 Comment by: ar...@php.net
 Reported by:jb7815 at gmail dot com
 Summary:New function request
 Status: Open
 Type:   Feature/Change Request
 Package:Unknown/Other Function
 Operating System:   All
 PHP Version:Irrelevant
 Block user comment: N
 Private report: N

 New Comment:

This can be done with array_merge_recursive().


Previous Comments:

[2012-12-11 17:58:22] jb7815 at gmail dot com

Description:

Suggestion:
Could you please implement a function to merge associative arrays without 
overwriting duplicate keys.

Unless there already is one that I have missed?

I have provided a small example that works to a point that will demonstrate my 
idea.

Thanks. 

Test script:
---
function array_merge_assoc($array1, $array2){   
foreach($array2 as $key => $value){
if(array_key_exists($key, $array1)){
$result[$key] = array_merge($array1[$key], 
$array2[$key]);
unset($array2[$key]);
}else{
$result[$key] = $array2[$key];
}
}
return $result;
}
$userConfig = ['libraries' => ['database', 'session', 'security']];
$defaults = ['libraries' => ['benchmark' , 'event', 'error'],
   'helpers' => ['html','date','file']];
print_r(array_merge_assoc($userConfig,$defaults));

Expected result:

Array
(
[libraries] => Array
(
[0] => database
[1] => session
[2] => security
[3] => benchmark
[4] => event
[5] => error
)

[helpers] => Array
(
[0] => html
[1] => date
[2] => file
)

)







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


Bug #63780 [Opn->Fbk]: Segmentation fault when try to get $request

2012-12-16 Thread reeze
Edit report at https://bugs.php.net/bug.php?id=63780&edit=1

 ID: 63780
 Updated by: re...@php.net
 Reported by:php dot maks3w at virtualplanets dot net
 Summary:Segmentation fault when try to get $request
-Status: Open
+Status: Feedback
 Type:   Bug
 Package:SOAP related
 PHP Version:5.4.9
 Block user comment: N
 Private report: N

 New Comment:

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

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




Previous Comments:

[2012-12-15 18:06:17] php dot maks3w at virtualplanets dot net

Description:

Situation: Custom class which extend from SoapClient and override "public 
function __doRequest($request, $location, $action, $version, $one_way = null)"

$request can't be used to compare strings, instead throw a Segmentation Fault 
error.

$request looks like a C Pointer or any other type instead of a PHP String type

As workaround you can filter the variable passing the value through a function 
which return basically the same value of the argument passed as input (like 
ltrim) after that it's possible save the returned value and now is a normal PHP 
String and can be compared.

Test script:
---
FAILING CODE:
public $lastRequest;

function __doRequest($request, $location, $action, $version, $one_way = 0) {
$this->lastRequest = $request;
}

$this->assertEquals('SomeContent', $this->lastRequest); // Segmentation Faul.


WORKAROUND:
public $lastRequest;

function __doRequest($request, $location, $action, $version, $one_way = 0) {
$this->lastRequest = ltrim($request); // Pass $request through a function
}

$this->assertEquals('SomeContent', $this->lastRequest); // Works








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


Bug #63782 [Opn->Fbk]: php.ini not loaded by php-fpm unless -c switch is used

2012-12-16 Thread reeze
Edit report at https://bugs.php.net/bug.php?id=63782&edit=1

 ID: 63782
 Updated by: re...@php.net
 Reported by:infected817 at gmail dot com
 Summary:php.ini not loaded by php-fpm unless -c switch is
 used
-Status: Open
+Status: Feedback
 Type:   Bug
 Package:*Configuration Issues
 Operating System:   Ubuntu Desktop 12.10
 PHP Version:5.4.9
 Block user comment: N
 Private report: N

 New Comment:

It's compiled with: /etc/php5/fpm

Configuration File (php.ini) Path   */etc/php5/[fpm]*
Loaded Configuration File   (none)

but you try to load php.ini from: /etc/php5   <-- no fpm
it's different.


Previous Comments:

[2012-12-16 08:40:21] infected817 at gmail dot com

Description:

I am seeing an issue where PHP 5.4.9 I compile myself or installed via apt-get 
will not load the php.ini file even if it exists in the "Configuration File 
Path" unless I pass in a -c "/path/to/php.in" to start up PHP-FPM.

1. To reproduce, compile PHP 5.4.9 with these configuration options: 
--prefix=/usr/local/php-5.4.9 --with-config-file-path=/etc/php5/

2. Run make & make install.

3. Copy the stock php.ini-development to /etc/php5/php.ini

4. Create a phpinfo() file on the webserver.

5. Start PHP-FPM and browse to that phpinfo() file.

6. See the following result in the output:

Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   (none)

7. However, if we start PHP-FPM with the -c switch: 
./php-fpm --fpm-config /etc/php5/php-fpm.conf -c /etc/php5/php.ini

We see that php.ini is loaded:
Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   php.ini


The configuration is not loaded at all unless you explicitly pass it using the 
-c switch to php.ini. That is even though php.ini resides in the "Configuration 
File Path"

 

Expected result:

php.ini should be loaded since it is in the "Configuration File Path"

Actual result:
--
php.ini is not loaded at all, even though it exists in the "Configuration File 
Path"






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


[PHP-BUG] Bug #63782 [NEW]: php.ini not loaded by php-fpm unless -c switch is used

2012-12-16 Thread infected817 at gmail dot com
From: infected817 at gmail dot com
Operating system: Ubuntu Desktop 12.10
PHP version:  5.4.9
Package:  *Configuration Issues
Bug Type: Bug
Bug description:php.ini not loaded by php-fpm unless -c switch is used

Description:

I am seeing an issue where PHP 5.4.9 I compile myself or installed via
apt-get will not load the php.ini file even if it exists in the
"Configuration File Path" unless I pass in a -c "/path/to/php.in" to start
up PHP-FPM.

1. To reproduce, compile PHP 5.4.9 with these configuration options:
--prefix=/usr/local/php-5.4.9 --with-config-file-path=/etc/php5/

2. Run make & make install.

3. Copy the stock php.ini-development to /etc/php5/php.ini

4. Create a phpinfo() file on the webserver.

5. Start PHP-FPM and browse to that phpinfo() file.

6. See the following result in the output:

Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   (none)

7. However, if we start PHP-FPM with the -c switch: 
./php-fpm --fpm-config /etc/php5/php-fpm.conf -c /etc/php5/php.ini

We see that php.ini is loaded:
Configuration File (php.ini) Path   /etc/php5/fpm
Loaded Configuration File   php.ini


The configuration is not loaded at all unless you explicitly pass it using
the -c switch to php.ini. That is even though php.ini resides in the
"Configuration File Path"

 

Expected result:

php.ini should be loaded since it is in the "Configuration File Path"

Actual result:
--
php.ini is not loaded at all, even though it exists in the "Configuration
File Path"

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