#44994 [Com]: exec() produces zombie processes on Windows, hangs Apache

2008-07-22 Thread efesar at gmail dot com
 ID:   44994
 Comment by:   efesar at gmail dot com
 Reported By:  dbarrett at vistaprint dot com
 Status:   Assigned
 Bug Type: Program Execution
 Operating System: Windows 2003 Server, 64-bit
 PHP Version:  5.2.6
 Assigned To:  pajoye
 New Comment:

I just upgraded from PHP 5.1.2 to 5.2.6, and this exact problem happens
to me. The exec and shell_exec used to work, and now they don't. They
hang the php process, and every subsequent call to exec produces a lost
cmd.exe ... 

Incidentally passthru() causes the same behavior.

Maybe it has something to do with the rotatelogs.exe ... somebody
earlier mentioned that it was waiting on c:\Apache2\logs\error.log ... 


So, basically, we can't run any system calls whatsoever via PHP. I
don't want to use a COM object, because I like portable code ... but
that might be the best step until this bug is fixed.


Previous Comments:


[2008-07-07 18:57:12] stephen dot cuppett at sas dot com

I am also experiencing this problem.  I have been able to recreate it
with system() as well as proc_open().  With proc_open() it doesn't seem
to matter if I set bypass_shell or not, just determines whether I have a
dangling cmd.exe process or not...

cmd.exe seems to stop at Wait:UserReq, but that probably doesn't mean
much.

I am able to reproduce it with XAMPP 1.6.6a (PHP 5.2.5) on Windows XP
or Windows Server 2003 (32-bit).

I don't have much to add in terms of documentation as I don't get
anything in the httpd logs, but using the following code snippet:

protected function runSAS($filename) {
$this->log("Requested to run SAS file:
" . $filename, LOG_DEBUG);

$toRun  = "\"" . SAS . "\"";
$toRun .= " -sysin '" . $filename .
"'";
$toRun .= " -CONFIG '" . SASV9CFG .
"'";
$toRun .= " -PRINT '" . TEMP_DIR . "/"
. basename($filename) . ".lst'";
$toRun .= " -LOG '" . TEMP_DIR . "/" .
basename($filename) . ".log'";
$toRun .= " -NOSPLASH";

$this->log("SAS command to run: " .
$toRun, LOG_DEBUG);

$descriptorspec = array(
0 => array("pipe",
"r"),  // stdin is a pipe that the child will read from
1 => array("pipe",
"w"),  // stdout is a pipe that the child will write to
2 => array("pipe", "w")
  // stderr is a file to write to
);

$res = proc_open($toRun,
$descriptorspec, $pipes, null, null, array(/*"bypass_shell" =>
true*/));

if (is_resource($res)) {
//fwrite($pipes[0],
"exit\n");
//fflush($pipes[0]);
fclose($pipes[0]);
fclose($pipes[1]);
fclose($pipes[2]);

$return_value =
proc_close($res);

$this->log("Return
value from SAS: " . $return_value, LOG_DEBUG);
}
}


When it does seem to complete, I'll get this in my log:

2008-06-26 20:23:55 Debug: Return value from SAS: 1

Nothing should come out on the pipes at all and when I set it up to
read those and it completes, there is no data read.  However, in a hang
case, PHP blocks reading STDOUT instead of on proc_close never getting
any data... even if I set the stream to be non-blocking on the pipe
explicitely after proc_open.



[2008-05-29 13:21:51] dbarrett at vistaprint dot com

I replaced all occurrences of exec() and shell_exec() in MediaWiki with
calls to a custom COM object that invokes programs.  The problem went
away. This strongly suggests that PHP's implementation of exec(0 and
shell_exec() is the culprit. I suspect a race condition.



[2008-05-14 15:09:43] dbarrett at vistaprint dot com

Description:

This is an intermittent but fatal problem. I cannot reproduce it on
demand, but it occurs regularly on our MediaWiki 1.12.0 site running on
Apache 2.2.8.

When invoking a non-interactive Microsoft Windows command via exec() or
shell_exe

#40034 [Com]: mssql_connect(): Unable to connect to server

2008-07-22 Thread efesar at gmail dot com
 ID:   40034
 Comment by:   efesar at gmail dot com
 Reported By:  chris dot clos at lmcu dot org
 Status:   Assigned
 Bug Type: MSSQL related
 Operating System: Windows Server 2003
 PHP Version:  5.2.0
 Assigned To:  fmk
 New Comment:

Recently I upgraded to PHP 5.2.6 (Apache 2.2.9, Win2003 SP2, MSSQL 2000
SP4 on a separate box) from 5.1.2 (Apache 2.0.58) and this problem
suddenly reared its ugly head. Apache wouldn't connect to the database
for more than a few hours. PHP was running the "2000.2.8.0" DLL ... I
copied the "2000.80.2273.0" DLL over from the MSSQL 2000 box and
restarted the web box. 

I'm hoping this fixes the issue. We tried to use Microsoft's 2005 PHP
driver, but it was hopelessly bad at managing resources (If we ran more
than 15 calls to sqlsrv_query() in a single PHP session, it crashed PHP
and Apache consistently). 

So far, so good. If this solution doesn't work within 72 hours to fix
the problem, I'll come back to add another comment so that people
reading this bug report will know it's still a problem. Otherwise, if
I'm not back in a week or so, assume the DLL swap is the fix. 

Incidentally, we also run a PostgreSQL box. We connect to both MSSQL
and PGSQL from the same web server, and the PGSQL connection has never
failed.


Previous Comments:


[2007-06-30 18:34:46] jmckinzie at novonics dot com

I may be having some similar behavior related to this bug. I'm having
issues with database connections dropping on a Win 2K3 box, running
Apache 1.3.37, PHP 5.1.6 and MS SQL 2005 Express. I am able to connect
most of the time using mssql_connect. However, on a consistent basis,
probably 15-45 minutes, my mssql_connect calls begin to fail with the
same message as above:

PHP Warning:  mssql_connect(): Unable to connect to server:  x.x.x.x

Restarting Apache fixes the problem and I am able to connect for a
short time. I'm using ntwdblib.dll, version 2000.80.194.0, and have not
upgraded to 2000.80.2039.0.



[2007-01-23 05:36:47] ivanvart at gmail dot com

We have the same problem... we solved (but we dont know if is the best
option) changing the ntwdblib.dll (ver. 2000.80.2039.0) in the php
directory.



[2007-01-22 21:18:17] tschoenbachler at eoncc dot com

I too has seen this problem on one of my customers machines and FYI,
restarting IIS temporarily fixes the problem. As a work around can I do
a regsvr32 on the new ntwdblib.dll and if so where can I get it...?



[2007-01-12 16:30:37] [EMAIL PROTECTED]

But you are packing the dll's :-)

As far as I know different versions of ntwdblib.dll will default to
either tcpip or netbios for the default protocol. There might also be a
registry setting for this (I'll look for that tonight when I get home).

Just copying the dll to the system does not give you access to the
client configuration tools that allow you to change the defaults or
create server aliases that should be used as the host parameter for
mssql_connect().

If the newer version of ntwdblib.dll solves the problem I'd say we
should bundle it.



[2007-01-12 14:11:43] [EMAIL PROTECTED]

Sorry, I'm not the MSSQL intiated :)

Frank, could you take a look please?



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/40034

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



#45599 [Opn->Ver]: strip_tags() truncates rest of string with invalid attribute

2008-07-22 Thread jani
 ID:   45599
 Updated by:   [EMAIL PROTECTED]
 Reported By:  david at grudl dot com
-Status:   Open
+Status:   Verified
 Bug Type: Strings related
 Operating System: *
 PHP Version:  5.2CVS, 5.3CVS, 6CVS (2008-07-22)


Previous Comments:


[2008-07-22 23:37:57] david at grudl dot com

Description:

Problematic backslash in HTML attribute (bug exists since PHP 5.2.2)

Reproduce code:
---
1) 
echo strip_tags('Hello  World');

2) this case is not HTML valid, but who cares...
echo strip_tags('Hello  World');

Expected result:

Hello  World

(in both cases)

Actual result:
--
Hello

(in both cases)





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



#45599 [NEW]: strip_tags

2008-07-22 Thread david at grudl dot com
From: david at grudl dot com
Operating system: windows xp
PHP version:  5.3CVS-2008-07-22 (snap)
PHP Bug Type: Strings related
Bug description:  strip_tags

Description:

Problematic backslash in HTML attribute (bug exists since PHP 5.2.2)

Reproduce code:
---
1) 
echo strip_tags('Hello  World');

2) this case is not HTML valid, but who cares...
echo strip_tags('Hello  World');

Expected result:

Hello  World

(in both cases)

Actual result:
--
Hello

(in both cases)

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



#45294 [Com]: phpcli and ms sql

2008-07-22 Thread kian dot mohageri at gmail dot com
 ID:   45294
 Comment by:   kian dot mohageri at gmail dot com
 Reported By:  lowee at lowee dot net
 Status:   No Feedback
 Bug Type: PDO related
 Operating System: windows 2003
 PHP Version:  5.2.6
 New Comment:

Very similar problem here with pdo_dblib.  Works fine under Apache
module, but not CLI.

I've tried to ensure everything was built correctly.



> php testpdo.php

Fatal error: Uncaught exception 'PDOException' with message
'SQLSTATE[HY000] Server is unavailable or does not exist. (severity 9)'
in /usr/home/kian/public_html/testpdo.php:5
Stack trace:
#0 /usr/home/kian/public_html/testpdo.php(5):
PDO->__construct('dblib:host=odys...', 'foo', 'bar')
#1 {main}
  thrown in /usr/home/kian/public_html/testpdo.php on line 5

> php -v
PHP 5.2.6 with Suhosin-Patch 0.9.6.2 (cli) (built: Jul 22 2008
16:30:13) (DEBUG)
Copyright (c) 1997-2008 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies

FreeBSD 7.0.


Previous Comments:


[2008-07-14 01:00:01] php-bugs at lists dot php dot net

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



[2008-07-06 12:05:51] [EMAIL PROTECTED]

Check what php.ini file is actually loaded. Most likely you're just
missing the proper extensions. Then change that script a bit:

getMessage();
}
?>

And post the output here.




[2008-06-17 11:13:30] lowee at lowee dot net

Description:

php cli with pdo and ms sql
it is working on any web browser but on php cli it is not working 

Reproduce code:
---
define('DB_HOST','192.168.1.20');
# mtc_awdb
# mtc_hds
define('DB_NAME','db1');
define('DB_USER','user');
define('DB_PASS','pass');

$dbhandle = mssql_connect(DB_HOST, DB_USER, DB_PASS) or die("Couldn't
connect to SQL Server on");
try {
 $pdo = new
PDO('mssql:host='.DB_HOST.';dbname='.DB_NAME,DB_USER,DB_PASS);
}catch (PDOException $e) {
print $e->getMessage();
}

Expected result:

to show me that it is connected


Actual result:
--
1 - SQLSTATE[01002] Unable to connect: SQL Server is unavailable or
does not exist.
(severity 9)
2 - SERVER not available 





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



#45516 [Asn->Fbk]: PGSQL seems to crash apache.

2008-07-22 Thread pajoye
 ID:   45516
 Updated by:   [EMAIL PROTECTED]
 Reported By:  twilightthorn dot kh at gmail dot com
-Status:   Assigned
+Status:   Feedback
 Bug Type: PostgreSQL related
 Operating System: Windows Vista Business
 PHP Version:  5.2.6
 Assigned To:  pajoye
 New Comment:

Can you post a link to the script (please try to make it small) or mail
me please?


Previous Comments:


[2008-07-22 22:28:12] [EMAIL PROTECTED]

Pierre, feedback was given..



[2008-07-15 10:20:15] twilightthorn dot kh at gmail dot com

Trying to run the file through the command line makes the CLI crash as
well.
The system logged this for CLI's crash:
---
Faulting application php.exe, version 5.2.6.6, time stamp 0x481b8f60,
faulting module ntdll.dll, version 6.0.6000.16386, time stamp
0x4549bdc9, exception code 0xc0fd, fault offset 0x000447f2, process
id 0x1398, application start time 0x01c8e660c8bcb334.
---


As for your Back-trace, I hope this covers it. :)

---
Thread 0 - System ID 4972
Entry point   php+2fc2 
Create time   7/15/2008 3:06:11 AM 
Time spent in user mode   0 Days 0:0:1.497 
Time spent in kernel mode   0 Days 0:0:13.88 






Function Arg 1 Arg 2 Arg 3   Source 
ntdll!_SEH_prolog4+1a 00413398 004133c0 
ntdll!RtlAllocateHeap+17c 0014  021a
ntdll!RtlpDosPathNameToRelativeNtPathName_Ustr+97 0001
00413330 004133cc
ntdll!RtlpDosPathNameToRelativeNtPathName_U+61 0001
7ffdec00 004133cc
ntdll!RtlDosPathNameToRelativeNtPathName_U+18 7ffdec00 004133cc
004133c0
kernel32!FindFirstFileExW+a0 7ffdec00  00413684   

kernel32!FindFirstFileA+44 0229b770 00413a28 022bd789
php5ts!virtual_file_ex+6d3 052ae270  003a2638
php5ts!php_stat+1c5 00414e58 003a 
ntdll!RtlpLowFragHeapAllocFromContext+a6f 0018 01970b40
1019ba22
php5ts!ts_resource_ex+15 0226a380 0004 
php5ts!ecalloc+13 0196eb18 003a2638 003a2638
php5ts!execute+b48   




NTDLL!_SEH_PROLOG4+1AIn
php__PID__4724__Date__07_15_2008__Time_03_06_41AM__649__Second_Chance_Exception_C0FD.dmp
the assembly instruction at ntdll!_SEH_prolog4+1a in
C:\Windows\System32\ntdll.dll from Microsoft Corporation has caused a
stack overflow exception (0xC0FD) when trying to write to memory
location 0x00412fdc on thread 0

Module Information 
Image Name: C:\Windows\System32\ntdll.dll   Symbol Type:  PDB 
Base address: 0x7770   Time Stamp:  Thu Nov 02 02:43:37 2006  
Checksum: 0x00128171   Comments:   
COM DLL: False   Company Name:  Microsoft Corporation 
ISAPIExtension: False   File Description:  NT Layer DLL 
ISAPIFilter: False   File Version:  6.0.6000.16386
(vista_rtm.061101-2205) 
Managed DLL: False   Internal Name:  ntdll.dll 
VB DLL: False   Legal Copyright:  © Microsoft Corporation. All rights
reserved. 
Loaded Image Name:  ntdll.dll   Legal Trademarks:   
Mapped Image Name: Original filename:  ntdll.dll 
Module name:  ntdll   Private Build:   
Single Threaded:  False   Product Name:  Microsoft® Windows® Operating
System 
Module Size:  1.12 MBytes   Product Version:  6.0.6000.16386 
Symbol File Name: 
c:\symcache\ntdll.pdb\C0A498F0036E4D4FB5CBF69005B0F9242\ntdll.pdb  
Special Build:  & 




Really, thanks for the dedication on this. I'd like to see more people
as devoted as you are to fixing problems. 

Best regards,
Thomas



[2008-07-15 09:07:36] [EMAIL PROTECTED]

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.



Can you try it in CLI as well? (in the cmd line php.exe yourscript.php)



[2008-07-15 09:01:59] twilightthorn dot kh at gmail dot com

Still no go... :( 

System logs the same error, Apache is still crashing.
To be sure it wasn't JUST Apache, I've tested my server by placing some
massive load on it. Apache did not crash after well over 4 minutes of
work, work that kept my CPU clocked at 100% for the duration. The PGSQL,
and PDO_PGSQL extensions both initialized for this test.

I'm coming to think that maybe the problem isn't with the PGSQL
extensio

#45592 [Bgs]: eval'ed Code throws HTTP 500 error when display_errors is off

2008-07-22 Thread andy at boeckler dot org
 ID:   45592
 User updated by:  andy at boeckler dot org
 Reported By:  andy at boeckler dot org
 Status:   Bogus
 Bug Type: Output Control
 Operating System: Linux
 PHP Version:  5.2.6
 New Comment:

"Changed error handler to send HTTP 500 instead of blank page on PHP
errors. "

1. I've never seen a blank page in PHP4, when i'm doing @eval !
2. Why does it work with display_errors on?
3. Why does it work, when i'm doing an "echo" BEFORE the @eval?


Previous Comments:


[2008-07-22 23:12:52] [EMAIL PROTECTED]

That's expected behavior. 

In PHP 5.2.4 NEWS:
"Changed error handler to send HTTP 500 instead of blank page on PHP
errors. "

And in the manual page for eval(): http://docs.php.net/eval

"If there is a parse error in the evaluated code, eval() returns FALSE
and execution of the following code continues normally. It is not
possible to catch a parse error in eval()  using set_error_handler()."




[2008-07-22 22:53:10] andy at boeckler dot org

Sorry .. 
the code example goes in the wrong direction 
I've narrowed the actual issue. It has to do with evaled code.
The @eval-Function is not catched properly.





[2008-07-22 22:15:59] [EMAIL PROTECTED]

You have a parse error there:

PHP Parse error:  syntax error, unexpected T_STRING, expecting
T_VARIABLE in /home/jani/t.php on line 7

And I don't get any E_STRICT notices with fixed version of this code
either..



[2008-07-22 15:25:38] andy at boeckler dot org

Update:
ob_flush() doesn't change anything ...
I accidentally tested it with display_errors=ON



[2008-07-22 15:13:17] andy at boeckler dot org

Description:

I'm getting Ajax-Request-Failures since PHP5 throws HTTP-500 Errors
back.
This was not the case before upgrading from PHP4.

This is annoying:
* E_STRICT are filtered out
* when display_errors is ON, the request is OK!
* display_errors ON is no option on a productionserver

It only works, when ob_flush() is called before exit() (see
staticFunc2)

Reproduce code:
---


Expected result:

HTTP 200

Actual result:
--
HTTP 500, w/o ob_flush() when display_errors is off
HTTP 200, w/o ob_flush() when display_errors is ON
HTTP 200, with ob_flush()





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



#45592 [Opn->Bgs]: eval'ed Code throws HTTP 500 error when display_errors is off

2008-07-22 Thread jani
 ID:   45592
 Updated by:   [EMAIL PROTECTED]
 Reported By:  andy at boeckler dot org
-Status:   Open
+Status:   Bogus
 Bug Type: Output Control
 Operating System: Linux
 PHP Version:  5.2.6
 New Comment:

That's expected behavior. 

In PHP 5.2.4 NEWS:
"Changed error handler to send HTTP 500 instead of blank page on PHP
errors. "

And in the manual page for eval(): http://docs.php.net/eval

"If there is a parse error in the evaluated code, eval() returns FALSE
and execution of the following code continues normally. It is not
possible to catch a parse error in eval()  using set_error_handler()."



Previous Comments:


[2008-07-22 22:53:10] andy at boeckler dot org

Sorry .. 
the code example goes in the wrong direction 
I've narrowed the actual issue. It has to do with evaled code.
The @eval-Function is not catched properly.





[2008-07-22 22:15:59] [EMAIL PROTECTED]

You have a parse error there:

PHP Parse error:  syntax error, unexpected T_STRING, expecting
T_VARIABLE in /home/jani/t.php on line 7

And I don't get any E_STRICT notices with fixed version of this code
either..



[2008-07-22 15:25:38] andy at boeckler dot org

Update:
ob_flush() doesn't change anything ...
I accidentally tested it with display_errors=ON



[2008-07-22 15:13:17] andy at boeckler dot org

Description:

I'm getting Ajax-Request-Failures since PHP5 throws HTTP-500 Errors
back.
This was not the case before upgrading from PHP4.

This is annoying:
* E_STRICT are filtered out
* when display_errors is ON, the request is OK!
* display_errors ON is no option on a productionserver

It only works, when ob_flush() is called before exit() (see
staticFunc2)

Reproduce code:
---


Expected result:

HTTP 200

Actual result:
--
HTTP 500, w/o ob_flush() when display_errors is off
HTTP 200, w/o ob_flush() when display_errors is ON
HTTP 200, with ob_flush()





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



#45546 [Com]: PCRE with utf8 kill apache childprocess

2008-07-22 Thread nikolas dot hagelstein at gmail dot com
 ID:   45546
 Comment by:   nikolas dot hagelstein at gmail dot com
 Reported By:  kaiser at macbureau dot de
 Status:   Feedback
 Bug Type: PCRE related
 Operating System: FreeBSD 7
 PHP Version:  5.2.6
 New Comment:

Confirmed. 

System:
FreeBSD 7
PHP 5.2.6 (PCRE Library Version => 7.6 2008-01-28)
stack size  (kbytes, -s) 524288

Backtrace:

#6216 0x00080407a494 in match () from
/usr/local/lib/php/20060613/pcre.so
#
#6217 0x00080407701c in match () from
/usr/local/lib/php/20060613/pcre.so
#
#6218 0x00080407a494 in match () from
/usr/local/lib/php/20060613/pcre.so
#
#6219 0x00080407701c in match () from
/usr/local/lib/php/20060613/pcre.so
#
#6220 0x000804076d05 in match () from
/usr/local/lib/php/20060613/pcre.so
#
#6221 0x00080407f12f in php_pcre_exec ()
#
   from /usr/local/lib/php/20060613/pcre.so
#
 
#
#6222 0x000804084c02 in php_pcre_match_impl ()
#
   from /usr/local/lib/php/20060613/pcre.so
#
#6223 0x00080408569b in php_do_pcre_match ()
#
   from /usr/local/lib/php/20060613/pcre.so
#
#6224 0x00538912 in zend_do_fcall_common_helper_SPEC ()
#
#6225 0x00528603 in execute ()
#
#6226 0x005383a4 in zend_do_fcall_common_helper_SPEC ()
#
#6227 0x00528603 in execute ()
#
#6228 0x00508dd3 in zend_execute_scripts ()
#
#6229 0x004c5a5d in php_execute_script ()


Previous Comments:


[2008-07-19 12:19:46] [EMAIL PROTECTED]

I can reproduce. (PHP 5.2.7-dev)

==6244== Stack overflow in thread 1: can't grow stack to 0xBE04DFC0
==6244== 
==6244== Process terminating with default action of signal 11
(SIGSEGV)
==6244==  Access not within mapped region at address 0xBE04DFC0
==6244==at 0x8099F78: match (pcre_exec.c:1287)
==6244== Stack overflow in thread 1: can't grow stack to 0xBE04DF9C
==6244== 
==6244== Process terminating with default action of signal 11
(SIGSEGV)
==6244==  Access not within mapped region at address 0xBE04DF9C
==6244==at 0x401D200: _vgnU_freeres (vg_preloaded.c:56)




[2008-07-19 11:13:41] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

For Windows (installer):

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

I can't reproduce the crash here, nor valgrind finds any problem. Can
you please try the cvs version please?



[2008-07-17 19:29:53] kaiser at macbureau dot de

Sorry, c&p error, thanks, looking forward to hear from you.

./test.php
Segmentation fault (core dumped)




#!/usr/local/bin/php




[2008-07-17 17:53:51] [EMAIL PROTECTED]

the pasted code is incomplete (doesn't even run). Please provide a
complete, but short, reproducible script.



[2008-07-17 16:31:50] kaiser at macbureau dot de

Description:

PCRE with utf8 (Typo3 Mailform) kills apache childprocess. With the 
following entry in apache errorlog on FreeBSD 7 with Apache 2.2.8:

[notice] child pid 6709 exit signal Illegal instruction (4)


Output of ulimit -a:

core file size  (blocks, -c) unlimited
data seg size   (kbytes, -d) 33554432
file size   (blocks, -f) unlimited
max locked memory   (kbytes, -l) unlimited
max memory size (kbytes, -m) unlimited
open files  (-n) 11095
pipe size(512 bytes, -p) 1
stack size  (kbytes, -s) 524288
cpu time   (seconds, -t) unlimited
max user processes  (-u) 5547
virtual memory  (kbytes, -v) unlimite

Reproduce code:
---
#!/usr/local/bin/php







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



#45597 [Bgs]: child pid 19433 exit signal Bus error

2008-07-22 Thread balraj dot v at netaxis dot in
 ID:   45597
 User updated by:  balraj dot v at netaxis dot in
 Reported By:  balraj dot v at netaxis dot in
 Status:   Bogus
 Bug Type: Apache2 related
 Operating System: RHEL 4
 PHP Version:  5.2.6
 New Comment:

Hi Thanks for your reply. We have not enable the any Zend or other 3rd
party extensions.

Please help me to resolve this issue.


Previous Comments:


[2008-07-22 22:03:38] [EMAIL PROTECTED]

"Always disable any Zend or other 3rd party extensions" reads in the
"report a bug" page. You have a 3rd party extension enabled. If you can
reproduce this without ANY 3rd party extensions and/or patches, reopen.




[2008-07-22 19:17:02] balraj dot v at netaxis dot in

Description:

We have dedicated server on that Drupal based flash archade website has
hosted. Per day 2500 visitors and 150 users are online normally.  Now
server creating the Signal Bus error and Apache gets crash.  If you
possible please help me to resolve this issue.

 # grep 'exit signal Bus' error_log

 [Wed Jul 16 21:18:45 2008] [notice] child pid 19433 exit signal Bus
error
 (7)
 [Wed Jul 16 22:12:56 2008] [notice] child pid 22194 exit signal Bus
error
 (7)
 [Wed Jul 16 23:08:53 2008] [notice] child pid 31096 exit signal Bus
error
 (7)
 [Wed Jul 16 23:30:29 2008] [notice] child pid 1139 exit signal Bus
error
 (7)
 [Thu Jul 17 00:09:58 2008] [notice] child pid 3336 exit signal Bus
error
 (7)
 [Thu Jul 17 00:28:03 2008] [notice] child pid 6256 exit signal Bus
error
 (7)
 [Thu Jul 17 00:53:55 2008] [notice] child pid 7459 exit signal Bus
error
 (7)

 We had test the Memory and Hardware test. But both of them passed (DC
people checked) and also RHEL4 OS Reload with 64 bit.

 Server Details:
 

 CPU   :  Intel(R) Xeon(R) CPU X3210 @ 2.13GHz (4 CPU)
 CPU MHz   :  2133.413
 RAM  :  4 GB
 Apache  :  2.0 (Previously tested with 2.2.9)
 PHP  :  5.2.5
 MySQL  :  5.0.1 (Running separate box)

 Current Apache Settings:
 --

 KeepAlive On
 MaxKeepAliveRequests 0
 KeepAliveTimeout 5
 UseCanonicalName Off
 http://www.webhostingtalk.com/showthread.php?t=706656&highlight=signal+bus+error
http://www.webhostingtalk.com/search.php?searchid=5837019






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



#45592 [Opn]: eval'ed Code throws HTTP 500 error when display_errors is off

2008-07-22 Thread andy at boeckler dot org
 ID:   45592
 User updated by:  andy at boeckler dot org
-Summary:  E_STRICT-warnings throws HTTP 500 error when
   display_errors is off
 Reported By:  andy at boeckler dot org
 Status:   Open
 Bug Type: Output Control
 Operating System: Linux
 PHP Version:  5.2.6
 New Comment:

changed summary.


Previous Comments:


[2008-07-22 22:53:10] andy at boeckler dot org

Sorry .. 
the code example goes in the wrong direction 
I've narrowed the actual issue. It has to do with evaled code.
The @eval-Function is not catched properly.





[2008-07-22 22:15:59] [EMAIL PROTECTED]

You have a parse error there:

PHP Parse error:  syntax error, unexpected T_STRING, expecting
T_VARIABLE in /home/jani/t.php on line 7

And I don't get any E_STRICT notices with fixed version of this code
either..



[2008-07-22 15:25:38] andy at boeckler dot org

Update:
ob_flush() doesn't change anything ...
I accidentally tested it with display_errors=ON



[2008-07-22 15:13:17] andy at boeckler dot org

Description:

I'm getting Ajax-Request-Failures since PHP5 throws HTTP-500 Errors
back.
This was not the case before upgrading from PHP4.

This is annoying:
* E_STRICT are filtered out
* when display_errors is ON, the request is OK!
* display_errors ON is no option on a productionserver

It only works, when ob_flush() is called before exit() (see
staticFunc2)

Reproduce code:
---


Expected result:

HTTP 200

Actual result:
--
HTTP 500, w/o ob_flush() when display_errors is off
HTTP 200, w/o ob_flush() when display_errors is ON
HTTP 200, with ob_flush()





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



#45592 [Fbk->Opn]: E_STRICT-warnings throws HTTP 500 error when display_errors is off

2008-07-22 Thread andy at boeckler dot org
 ID:   45592
 User updated by:  andy at boeckler dot org
 Reported By:  andy at boeckler dot org
-Status:   Feedback
+Status:   Open
 Bug Type: Output Control
 Operating System: Linux
 PHP Version:  5.2.6
 New Comment:

Sorry .. 
the code example goes in the wrong direction 
I've narrowed the actual issue. It has to do with evaled code.
The @eval-Function is not catched properly.




Previous Comments:


[2008-07-22 22:15:59] [EMAIL PROTECTED]

You have a parse error there:

PHP Parse error:  syntax error, unexpected T_STRING, expecting
T_VARIABLE in /home/jani/t.php on line 7

And I don't get any E_STRICT notices with fixed version of this code
either..



[2008-07-22 15:25:38] andy at boeckler dot org

Update:
ob_flush() doesn't change anything ...
I accidentally tested it with display_errors=ON



[2008-07-22 15:13:17] andy at boeckler dot org

Description:

I'm getting Ajax-Request-Failures since PHP5 throws HTTP-500 Errors
back.
This was not the case before upgrading from PHP4.

This is annoying:
* E_STRICT are filtered out
* when display_errors is ON, the request is OK!
* display_errors ON is no option on a productionserver

It only works, when ob_flush() is called before exit() (see
staticFunc2)

Reproduce code:
---


Expected result:

HTTP 200

Actual result:
--
HTTP 500, w/o ob_flush() when display_errors is off
HTTP 200, w/o ob_flush() when display_errors is ON
HTTP 200, with ob_flush()





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



#45314 [Opn]: wddx_serialize_value does not handle unicode properly

2008-07-22 Thread jani
 ID:   45314
 Updated by:   [EMAIL PROTECTED]
 Reported By:  mikx at mikx dot de
 Status:   Open
 Bug Type: WDDX related
 Operating System: *
 PHP Version:  5.2.6
 New Comment:

I guess (!) the fix for bug #37571 caused this problem.


Previous Comments:


[2008-06-19 12:48:52] mikx at mikx dot de

Description:

wddx_serialize_value does not deal as expected with unicode characters
in PHP 5.2.x or PHP 5.3.x. The function worked differently in PHP
5.1.6.

When serializing a string or a more complex objects any unicode
characters get again utf8 encoded - instead of getting in as is.


Reproduce code:
---
Demo (some chinese character)






"; 
echo utf8_encode($_GET["utf8"]).""; 
echo wddx_serialize_value($_GET["utf8"])."";
}
?>

Expected result:

The demo code is a little script that outputs the given query parameter
"utf8" in three way:

1. Directly as recieved
2. utf8_encoded
3. serialized via wddx_serialize_value

In <= 5.1.6 the resulting WDDX contained the utf8 characters excatly as
given. In >= 5.2.0 the string gets UTF8 encoded again, just as if you
would have valled utf8_encode on it.



Actual result:
--
While the new behavior might make sense for data going forward
(although i am not sure what the expected behavior by WDDX spec is) this
breaks backward compatibility with old data.

As we have millons of database rows in unicode WDDX data this is a huge
issue (at least to us).

Can you please clarify if this is a bug, the expected behavior going
forward and how to deal with backward compatibility issues (maybe an
additional parameter to control the behavior)?

This might be related to bug #41722





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



#45573 [Opn->Fbk]: unserialize does not work if a linebreak is inside the input string

2008-07-22 Thread jani
 ID:   45573
 Updated by:   [EMAIL PROTECTED]
-Summary:  unserialze does not work, if a linebreak is inside the
   input string
 Reported By:  t_mueller_stolzenhain at yahoo dot de
-Status:   Open
+Status:   Feedback
 Bug Type: IIS related
 Operating System: windows2003
 PHP Version:  5.2.6
 New Comment:

Please try using this CVS snapshot:

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

For Windows (installer):

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




Previous Comments:


[2008-07-20 20:23:11] t_mueller_stolzenhain at yahoo dot de

Description:

After updating PHP to version 5.2.6 on a windows 2003 server running
under IIS, it was not possible to update PEAR anymore. Each package
created some error messages like

Notice: unserialize(): Error at offset 1139 of 4783 bytes in
PEAR\Registry.php on line 1062


After putting the line

$data = str_replace("\15\12", "\12", $data);

before the unserialize-including line, the error message disappeared an
I was able to update PEAR again.

I asume, this is an IIS related issue, because on an other Computer
with PHP 5.2.5 (running on Win XP and Apache) are no error messages.

Reproduce code:
---
These are the lines 1058-1064 from /PEAR/PEAR/Registry.php including
one line with an fix

$this->_closePackageFile($fp);
$data = file_get_contents($this->_packageFileName($package,
$channel));
set_magic_quotes_runtime($rt);
$data = str_replace("\15\12", "\12", $data);//additional line
with fix
$data = unserialize($data);
if ($key === null) {
return $data;
}

Expected result:

no error message

Actual result:
--
e.g.

Notice: unserialize(): Error at offset 1139 of 4783 bytes in
PEAR\Registry.php on line 1062






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



#45577 [Opn->Fbk]: Integer overflow connecting to https soap service

2008-07-22 Thread jani
 ID:   45577
 Updated by:   [EMAIL PROTECTED]
 Reported By:  contact at reubidium dot com
-Status:   Open
+Status:   Feedback
 Bug Type: SOAP related
 Operating System: Mac OS X 10.5.4
 PHP Version:  5.2.6
 New Comment:

Please try using this CVS snapshot:

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

For Windows (installer):

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




Previous Comments:


[2008-07-21 10:02:55] contact at reubidium dot com

I also added this as a bug over at MacPorts.org:
https://trac.macports.org/ticket/16036



[2008-07-21 09:55:59] contact at reubidium dot com

Description:

With version 5.2.6 of PHP installed from MacPorts, I was saddened to
find that all the SOAP calls in my application were suddenly broken,
kicking up the following PHP Fatal error:  
Uncaught SoapFault exception: [Client] Possible integer overflow in
memory allocation (3819152321 * 4 + 0)

This app was working fine in my Entropy PHP 5.2.5 package, and
switching back to that all my soap calls were once again working fine.

Since all the calls were via https, I thought this would be a good
first thing to try changing.  so I found a public http soap service and
ran a quick test, and things worked just fine then.  

I should mention that I have the max memory setting in my php.ini set
at 256M currently, but I had tried increasing it to 512M with no
effect.. not that that should matter, this is a small soap request I am
dealing with.


Reproduce code:
---
$client = new
SoapClient('https://api.store.sinatra.iventa.com/UserService.asmx?WSDL');

Expected result:

A valid SOAP client object

Actual result:
--
PHP Fatal error:  Uncaught SoapFault exception: [Client] Possible
integer overflow in memory allocation (3819152321 * 4 + 0) 






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



#45566 [Opn->Fbk]: Strict comparision on $_SERVER values fail

2008-07-22 Thread jani
 ID:   45566
 Updated by:   [EMAIL PROTECTED]
 Reported By:  samuel at slbdata dot se
-Status:   Open
+Status:   Feedback
 Bug Type: Strings related
 Operating System: Ubuntu 8.04.1
 PHP Version:  6CVS-2008-07-19 (snap)
 New Comment:

Try var_dump() on those variables.


Previous Comments:


[2008-07-19 20:43:38] samuel at slbdata dot se

Description:

Comparing a string in the $_SERVER superglobal using the strict
equality operator (===) always fails, even though both types are
strings. $_GET and other variables work fine.

I'm using the php.ini-recommended file, with no changes except for
display_(startup_)errors which are enabled. My locale is sv_SE.UTF-8
(the LANG environment variable is set to this value)

This used to work fine in php6.0-200804260630

Reproduce code:
---
\n";
if (($rm !== 'GET') && ($rm == 'GET')) {
  echo "Bug! \n";
} else {
  echo "Correct behaviour! \n";
}


$sp = $_SERVER['SERVER_PROTOCOL'];
echo "Type is: ".gettype($sp)." \n";
if (($sp !== 'HTTP/1.1') && ($sp == 'HTTP/1.1')) {
  echo "Bug! \n";
} else {
  echo "Correct behaviour! \n";
}


Expected result:

Type is: string
Correct behaviour! 
Type is: string
Correct behaviour! 


Actual result:
--
Type is: string
Bug!
Type is: string
Bug! 






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



#45516 [Opn->Asn]: PGSQL seems to crash apache.

2008-07-22 Thread jani
 ID:   45516
 Updated by:   [EMAIL PROTECTED]
 Reported By:  twilightthorn dot kh at gmail dot com
-Status:   Open
+Status:   Assigned
 Bug Type: PostgreSQL related
 Operating System: Windows Vista Business
 PHP Version:  5.2.6
 Assigned To:  pajoye
 New Comment:

Pierre, feedback was given..


Previous Comments:


[2008-07-15 10:20:15] twilightthorn dot kh at gmail dot com

Trying to run the file through the command line makes the CLI crash as
well.
The system logged this for CLI's crash:
---
Faulting application php.exe, version 5.2.6.6, time stamp 0x481b8f60,
faulting module ntdll.dll, version 6.0.6000.16386, time stamp
0x4549bdc9, exception code 0xc0fd, fault offset 0x000447f2, process
id 0x1398, application start time 0x01c8e660c8bcb334.
---


As for your Back-trace, I hope this covers it. :)

---
Thread 0 - System ID 4972
Entry point   php+2fc2 
Create time   7/15/2008 3:06:11 AM 
Time spent in user mode   0 Days 0:0:1.497 
Time spent in kernel mode   0 Days 0:0:13.88 






Function Arg 1 Arg 2 Arg 3   Source 
ntdll!_SEH_prolog4+1a 00413398 004133c0 
ntdll!RtlAllocateHeap+17c 0014  021a
ntdll!RtlpDosPathNameToRelativeNtPathName_Ustr+97 0001
00413330 004133cc
ntdll!RtlpDosPathNameToRelativeNtPathName_U+61 0001
7ffdec00 004133cc
ntdll!RtlDosPathNameToRelativeNtPathName_U+18 7ffdec00 004133cc
004133c0
kernel32!FindFirstFileExW+a0 7ffdec00  00413684   

kernel32!FindFirstFileA+44 0229b770 00413a28 022bd789
php5ts!virtual_file_ex+6d3 052ae270  003a2638
php5ts!php_stat+1c5 00414e58 003a 
ntdll!RtlpLowFragHeapAllocFromContext+a6f 0018 01970b40
1019ba22
php5ts!ts_resource_ex+15 0226a380 0004 
php5ts!ecalloc+13 0196eb18 003a2638 003a2638
php5ts!execute+b48   




NTDLL!_SEH_PROLOG4+1AIn
php__PID__4724__Date__07_15_2008__Time_03_06_41AM__649__Second_Chance_Exception_C0FD.dmp
the assembly instruction at ntdll!_SEH_prolog4+1a in
C:\Windows\System32\ntdll.dll from Microsoft Corporation has caused a
stack overflow exception (0xC0FD) when trying to write to memory
location 0x00412fdc on thread 0

Module Information 
Image Name: C:\Windows\System32\ntdll.dll   Symbol Type:  PDB 
Base address: 0x7770   Time Stamp:  Thu Nov 02 02:43:37 2006  
Checksum: 0x00128171   Comments:   
COM DLL: False   Company Name:  Microsoft Corporation 
ISAPIExtension: False   File Description:  NT Layer DLL 
ISAPIFilter: False   File Version:  6.0.6000.16386
(vista_rtm.061101-2205) 
Managed DLL: False   Internal Name:  ntdll.dll 
VB DLL: False   Legal Copyright:  © Microsoft Corporation. All rights
reserved. 
Loaded Image Name:  ntdll.dll   Legal Trademarks:   
Mapped Image Name: Original filename:  ntdll.dll 
Module name:  ntdll   Private Build:   
Single Threaded:  False   Product Name:  Microsoft® Windows® Operating
System 
Module Size:  1.12 MBytes   Product Version:  6.0.6000.16386 
Symbol File Name: 
c:\symcache\ntdll.pdb\C0A498F0036E4D4FB5CBF69005B0F9242\ntdll.pdb  
Special Build:  & 




Really, thanks for the dedication on this. I'd like to see more people
as devoted as you are to fixing problems. 

Best regards,
Thomas



[2008-07-15 09:07:36] [EMAIL PROTECTED]

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.



Can you try it in CLI as well? (in the cmd line php.exe yourscript.php)



[2008-07-15 09:01:59] twilightthorn dot kh at gmail dot com

Still no go... :( 

System logs the same error, Apache is still crashing.
To be sure it wasn't JUST Apache, I've tested my server by placing some
massive load on it. Apache did not crash after well over 4 minutes of
work, work that kept my CPU clocked at 100% for the duration. The PGSQL,
and PDO_PGSQL extensions both initialized for this test.

I'm coming to think that maybe the problem isn't with the PGSQL
extensions, but with my ntdll.dll. After all, these same extensions work
on other platforms, and have been found to work on Vista* OS's before,
right?

I've found that there is a later version of ntdll.dll on fo

#45592 [Opn->Fbk]: E_STRICT-warnings throws HTTP 500 error when display_errors is off

2008-07-22 Thread jani
 ID:   45592
 Updated by:   [EMAIL PROTECTED]
 Reported By:  andy at boeckler dot org
-Status:   Open
+Status:   Feedback
 Bug Type: Output Control
 Operating System: Linux
 PHP Version:  5.2.6
 New Comment:

You have a parse error there:

PHP Parse error:  syntax error, unexpected T_STRING, expecting
T_VARIABLE in /home/jani/t.php on line 7

And I don't get any E_STRICT notices with fixed version of this code
either..


Previous Comments:


[2008-07-22 15:25:38] andy at boeckler dot org

Update:
ob_flush() doesn't change anything ...
I accidentally tested it with display_errors=ON



[2008-07-22 15:13:17] andy at boeckler dot org

Description:

I'm getting Ajax-Request-Failures since PHP5 throws HTTP-500 Errors
back.
This was not the case before upgrading from PHP4.

This is annoying:
* E_STRICT are filtered out
* when display_errors is ON, the request is OK!
* display_errors ON is no option on a productionserver

It only works, when ob_flush() is called before exit() (see
staticFunc2)

Reproduce code:
---


Expected result:

HTTP 200

Actual result:
--
HTTP 500, w/o ob_flush() when display_errors is off
HTTP 200, w/o ob_flush() when display_errors is ON
HTTP 200, with ob_flush()





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



#45591 [Opn->Fbk]: Bus error on file_get_contents

2008-07-22 Thread jani
 ID:   45591
 Updated by:   [EMAIL PROTECTED]
 Reported By:  rommer at active dot by
-Status:   Open
+Status:   Feedback
 Bug Type: Reproducible crash
 Operating System: linux-2.6.x i386
 PHP Version:  5.2CVS-2008-07-22 (snap)
 New Comment:

I can not reproduce this. How about giving us the basic info:

1. the configure line
2. output of "php -v"
3. output of "php -m"



Previous Comments:


[2008-07-22 15:02:28] rommer at active dot by

Description:

"Bus error" calling file_get_contents

Reproduce code:
---


Expected result:

nothing

Actual result:
--
"Bus error"





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



#45594 [Bgs]: json_encode looses accentuated characters

2008-07-22 Thread jani
 ID:   45594
 Updated by:   [EMAIL PROTECTED]
 Reported By:  neonira at gmail dot com
 Status:   Bogus
 Bug Type: JSON related
 Operating System: windows XP
 PHP Version:  5.2.6
 New Comment:

Hint: You're not passing utf-8 here.. setlocale..


Previous Comments:


[2008-07-22 22:04:52] [EMAIL PROTECTED]

RTFM: "This function only works with UTF-8 encoded data."



[2008-07-22 15:32:45] neonira at gmail dot com

Description:

I checked that the file encoding character set for the php source file
is UTF-8. So it means, I provide a real UTF-8 entry, and I don't need to
use ut8_encode. 

It seems that accentuated caracters are truncated or not well managed
while json-encoding a string.



Reproduce code:
---
link = "http://www.neonira.com";;
 $this->str = "chaîne avec caractères accentués ... ";
 $this->arr = array(1, 3, "lala", "123", array ( 'a', 'b', 'c'),
134);
  }
}

$c = new CT();
$c->document();
echo json_encode($c);

?>

Expected result:

shell>php ../php/ct.php
{"link":"http:\/\/www.neonira.com","str":"chaîne avec caractères
accentués ... ","arr":[1,3,"lala","123",["a","b","c"],134]}shell>

Actual result:
--
shell>{107}php ../php/ct.php
{"link":"http:\/\/www.neonira.com","str":"cha","arr":[1,3,"lala","123",["a","b","c"],134]}shell>






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



#45594 [Opn->Bgs]: json_encode looses accentuated characters

2008-07-22 Thread jani
 ID:   45594
 Updated by:   [EMAIL PROTECTED]
 Reported By:  neonira at gmail dot com
-Status:   Open
+Status:   Bogus
 Bug Type: JSON related
 Operating System: windows XP
 PHP Version:  5.2.6
 New Comment:

RTFM: "This function only works with UTF-8 encoded data."


Previous Comments:


[2008-07-22 15:32:45] neonira at gmail dot com

Description:

I checked that the file encoding character set for the php source file
is UTF-8. So it means, I provide a real UTF-8 entry, and I don't need to
use ut8_encode. 

It seems that accentuated caracters are truncated or not well managed
while json-encoding a string.



Reproduce code:
---
link = "http://www.neonira.com";;
 $this->str = "chaîne avec caractères accentués ... ";
 $this->arr = array(1, 3, "lala", "123", array ( 'a', 'b', 'c'),
134);
  }
}

$c = new CT();
$c->document();
echo json_encode($c);

?>

Expected result:

shell>php ../php/ct.php
{"link":"http:\/\/www.neonira.com","str":"chaîne avec caractères
accentués ... ","arr":[1,3,"lala","123",["a","b","c"],134]}shell>

Actual result:
--
shell>{107}php ../php/ct.php
{"link":"http:\/\/www.neonira.com","str":"cha","arr":[1,3,"lala","123",["a","b","c"],134]}shell>






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



#45597 [Opn->Bgs]: child pid 19433 exit signal Bus error

2008-07-22 Thread jani
 ID:   45597
 Updated by:   [EMAIL PROTECTED]
 Reported By:  balraj dot v at netaxis dot in
-Status:   Open
+Status:   Bogus
 Bug Type: Apache2 related
 Operating System: RHEL 4
 PHP Version:  5.2.6
 New Comment:

"Always disable any Zend or other 3rd party extensions" reads in the
"report a bug" page. You have a 3rd party extension enabled. If you can
reproduce this without ANY 3rd party extensions and/or patches, reopen.



Previous Comments:


[2008-07-22 19:17:02] balraj dot v at netaxis dot in

Description:

We have dedicated server on that Drupal based flash archade website has
hosted. Per day 2500 visitors and 150 users are online normally.  Now
server creating the Signal Bus error and Apache gets crash.  If you
possible please help me to resolve this issue.

 # grep 'exit signal Bus' error_log

 [Wed Jul 16 21:18:45 2008] [notice] child pid 19433 exit signal Bus
error
 (7)
 [Wed Jul 16 22:12:56 2008] [notice] child pid 22194 exit signal Bus
error
 (7)
 [Wed Jul 16 23:08:53 2008] [notice] child pid 31096 exit signal Bus
error
 (7)
 [Wed Jul 16 23:30:29 2008] [notice] child pid 1139 exit signal Bus
error
 (7)
 [Thu Jul 17 00:09:58 2008] [notice] child pid 3336 exit signal Bus
error
 (7)
 [Thu Jul 17 00:28:03 2008] [notice] child pid 6256 exit signal Bus
error
 (7)
 [Thu Jul 17 00:53:55 2008] [notice] child pid 7459 exit signal Bus
error
 (7)

 We had test the Memory and Hardware test. But both of them passed (DC
people checked) and also RHEL4 OS Reload with 64 bit.

 Server Details:
 

 CPU   :  Intel(R) Xeon(R) CPU X3210 @ 2.13GHz (4 CPU)
 CPU MHz   :  2133.413
 RAM  :  4 GB
 Apache  :  2.0 (Previously tested with 2.2.9)
 PHP  :  5.2.5
 MySQL  :  5.0.1 (Running separate box)

 Current Apache Settings:
 --

 KeepAlive On
 MaxKeepAliveRequests 0
 KeepAliveTimeout 5
 UseCanonicalName Off
 http://www.webhostingtalk.com/showthread.php?t=706656&highlight=signal+bus+error
http://www.webhostingtalk.com/search.php?searchid=5837019






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



#45598 [Com]: Unable to query remote cataloged odbc

2008-07-22 Thread phil dot nyc at gmail dot com
 ID:   45598
 Comment by:   phil dot nyc at gmail dot com
 Reported By:  phil dot nyc at gmail dot com
 Status:   Open
 Bug Type: ODBC related
 Operating System: Aix 5.3 64-bit
 PHP Version:  5.3CVS-2008-07-22 (snap)
 New Comment:

I would like to follow up with a more detailed report that I've been
able to collect after spinning in circles on this problem for the last
couple of days (have gone through various versions of php5 and php4 and
compilers, and this is as close as I get)

=
SYSTEM SPECS
=

uname -a
AIX unnamed12a 3 5 000AD01ED700

CC=xlc_r  ./configure --enable-cli
--with-ibm-db2=/db2/v91p/db2lawp/sqllib --enable-pcntl 1>1 2>2

make

[EMAIL PROTECTED]: /usr/src/php5.3-200807211430>sapi/cli/php -v
PHP 5.3.0-dev (cli) (built: Jul 22 2008 15:42:32)
Copyright (c) 1997-2008 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2008 Zend Technologies

=
TEST SCRIPT
=




=
OUTPUT
=

[EMAIL PROTECTED]: /usr/src/php5.3-200807211430/sapi/cli>./php -f
/usr/dfkp/webscripts/test/db2.php
===
resource(5) of type (odbc link persistent)
select count(*) from dkactivity
resource(6) of type (odbc result)
int(4)
string(4) "4473"
===
resource(8) of type (odbc link persistent)
select count(*) from dfkdta10.bnncli with nc
resource(9) of type (odbc result)

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to
allocate 544696693 bytes) in /usr/dfkp/webscripts/test/db2.php on line
11

==
CONFIRM REMOTE DB2 DOES INDEED WORK
==

$ uname -a
AIX unnamed12a 3 5 000AD01ED700
$ who am i
db2lawp pts/1   Jul 22 15:57 (toshiba200601) 
$ db2 connect to prod81

   Database Connection Information

 Database server= DB2/AIX64 9.1.0
 SQL authorization ID   = DB2LAWP
 Local database alias   = PROD81

$ db2 "select count(*) from dkactivity"

1  
---
   4473

  1 record(s) selected.

$ db2 terminate
DB2I  The TERMINATE command completed successfully.
$ db2 connect to dfk01 user db2user
Enter current password for db2user: 

   Database Connection Information

 Database server= OS/400 5.4.0
 SQL authorization ID   = DB2USER
 Local database alias   = DFK01

$ db2 "select count(*) from dfkdta10.bnncli"

1  
---
   3570

  1 record(s) selected.

$ db2 terminate
DB2I  The TERMINATE command completed successfully.
$


Previous Comments:


[2008-07-22 20:12:01] phil dot nyc at gmail dot com

Description:

on Aix 5.3 64-bit, have db2 connect installed to connect to iSeries
db2, and local aix db2.

able to do so using the db2 command line client, but using php only
able to query local aix db2.

using php, able to connect to remote (iSeries) db2 but not able to
execute query!


Reproduce code:
---
http://pastebin.com/f462c54ee

Expected result:

resource(5) of type (odbc link persistent)
select count(*) from dkactivity
resource(6) of type (odbc result)
int(4)
string(4) "4473"
===
resource(8) of type (odbc link persistent)
select count(*) from dfkdta10.bnncli with nc
resource(9) of type (odbc result)
int(4)
string(4) "3570"


Actual result:
--
resource(5) of type (odbc link persistent)
select count(*) from dkactivity
resource(6) of type (odbc result)
int(4)
string(4) "4473"
===
resource(8) of type (odbc link persistent)
select count(*) from dfkdta10.bnncli with nc
resource(9) of type (odbc result)

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to
allocate 544696693 bytes) in /usr/dfkp/webscripts/test/db2.php on line
11






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



#45598 [NEW]: Unable to query remote cataloged odbc

2008-07-22 Thread phil dot nyc at gmail dot com
From: phil dot nyc at gmail dot com
Operating system: Aix 5.3 64-bit
PHP version:  5.3CVS-2008-07-22 (snap)
PHP Bug Type: ODBC related
Bug description:  Unable to query remote cataloged odbc

Description:

on Aix 5.3 64-bit, have db2 connect installed to connect to iSeries db2,
and local aix db2.

able to do so using the db2 command line client, but using php only able
to query local aix db2.

using php, able to connect to remote (iSeries) db2 but not able to execute
query!


Reproduce code:
---
http://pastebin.com/f462c54ee

Expected result:

resource(5) of type (odbc link persistent)
select count(*) from dkactivity
resource(6) of type (odbc result)
int(4)
string(4) "4473"
===
resource(8) of type (odbc link persistent)
select count(*) from dfkdta10.bnncli with nc
resource(9) of type (odbc result)
int(4)
string(4) "3570"


Actual result:
--
resource(5) of type (odbc link persistent)
select count(*) from dkactivity
resource(6) of type (odbc result)
int(4)
string(4) "4473"
===
resource(8) of type (odbc link persistent)
select count(*) from dfkdta10.bnncli with nc
resource(9) of type (odbc result)

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to
allocate 544696693 bytes) in /usr/dfkp/webscripts/test/db2.php on line 11


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



#45597 [NEW]: child pid 19433 exit signal Bus error

2008-07-22 Thread balraj dot v at netaxis dot in
From: balraj dot v at netaxis dot in
Operating system: RHEL 4
PHP version:  5.2.6
PHP Bug Type: Apache2 related
Bug description:  child pid 19433 exit signal Bus error

Description:

We have dedicated server on that Drupal based flash archade website has
hosted. Per day 2500 visitors and 150 users are online normally.  Now
server creating the Signal Bus error and Apache gets crash.  If you
possible please help me to resolve this issue.

 # grep 'exit signal Bus' error_log

 [Wed Jul 16 21:18:45 2008] [notice] child pid 19433 exit signal Bus
error
 (7)
 [Wed Jul 16 22:12:56 2008] [notice] child pid 22194 exit signal Bus
error
 (7)
 [Wed Jul 16 23:08:53 2008] [notice] child pid 31096 exit signal Bus
error
 (7)
 [Wed Jul 16 23:30:29 2008] [notice] child pid 1139 exit signal Bus error
 (7)
 [Thu Jul 17 00:09:58 2008] [notice] child pid 3336 exit signal Bus error
 (7)
 [Thu Jul 17 00:28:03 2008] [notice] child pid 6256 exit signal Bus error
 (7)
 [Thu Jul 17 00:53:55 2008] [notice] child pid 7459 exit signal Bus error
 (7)

 We had test the Memory and Hardware test. But both of them passed (DC
people checked) and also RHEL4 OS Reload with 64 bit.

 Server Details:
 

 CPU   :  Intel(R) Xeon(R) CPU X3210 @ 2.13GHz (4 CPU)
 CPU MHz   :  2133.413
 RAM  :  4 GB
 Apache  :  2.0 (Previously tested with 2.2.9)
 PHP  :  5.2.5
 MySQL  :  5.0.1 (Running separate box)

 Current Apache Settings:
 --

 KeepAlive On
 MaxKeepAliveRequests 0
 KeepAliveTimeout 5
 UseCanonicalName Off
 http://www.webhostingtalk.com/showthread.php?t=706656&highlight=signal+bus+error
http://www.webhostingtalk.com/search.php?searchid=5837019


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



#42708 [Opn->WFx]: json_decode: escape characters

2008-07-22 Thread jani
 ID:   42708
 Updated by:   [EMAIL PROTECTED]
 Reported By:  tjerk dot meesters at muvee dot com
-Status:   Open
+Status:   Wont fix
 Bug Type: JSON related
 Operating System: *
 PHP Version:  5.2.4
 New Comment:

1. "Fixing" this would violate the JSON spec. HEAD (aka PHP 6) also
behaves the same way now as other branches.

2. NULL is returned whenever you pass invalid data to json_decode().


Previous Comments:


[2007-11-23 00:45:20] [EMAIL PROTECTED]

php5.3-200711221930:

string(22) "Sir, you\'re an idiot!"
NULL
--

php6.0-200711202130:

string(22) "Sir, you\'re an idiot!"
string(26) "["Sir, you\'re an idiot!"]"



[2007-09-19 10:19:22] tjerk dot meesters at muvee dot com

Description:

When a single quote is being escaped, the json_decode() gives some
unexpected results.

1. According to the JSON specs, the single quote is not in the list of
characters that can follow the escape character (such as n, t, b, r,
etc.); however, JavaScript does recognize the single quote so it would
be very nice to have as a feature.

2. When wrapping a string with an escaped single quote inside an array
context, the json_decode() gives up and returns NULL.

Reproduce code:
---



Expected result:

string(21) "Sir, you're an idiot!"
array(1) {
  [0]=>
  string(21) "Sir, you're an idiot!"
}

Actual result:
--
string(22) "Sir, you\'re an idiot!"
NULL






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



#45590 [Opn->Bgs]: pcntl_fork() with MySQL queries

2008-07-22 Thread johannes
 ID:   45590
 Updated by:   [EMAIL PROTECTED]
 Reported By:  alan dot blotz at students dot uni-mainz dot de
-Status:   Open
+Status:   Bogus
 Bug Type: MySQL related
 Operating System: Debian Lenny
 PHP Version:  5.2.6
 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

You must not use the same connection from different processes. The
protocol only allows a single query per time so the queries from the
different childs end up in a queue and the answers are read by the
process which randomly expects some results at the correct time.


Previous Comments:


[2008-07-22 14:48:59] alan dot blotz at students dot uni-mainz dot de

Description:

Already a long time ago the bug http://bugs.php.net/bug.php?id=38228
was active, but I experienced some problems with the pcntl_fork()
function today. I already fixed the problem with multiple children
connecting to the MySQL server by using mysql_connect(..., true) or
mysql_pconnect() (the latter I'm using right now). My problem is, that
with any of these methods I'm partly getting wrong results to queries
(see code). This really NOT happening always, just sometimes when you
don't expect it.

I can't post the original code due to copyrights, but the example below
should give you an idea of what is happening. I'm working with multiple
children in my application (executed as CLI), at least five at a time.
Is it perhaps a memory problem of PHP and / or MySQL?


Alan

Reproduce code:
---
// Queries for five children
for ($i = 0; $i < 5; $i++) {

// If I am the child
if (!pcntl_fork()) {

switch ($i) {

case 0:
$sql = 'SELECT a, b FROM t';
break;
case 1:
$sql = 'SELECT c FROM s';
break;
case 2:
$sql = 'SELECT x FROM s';
break;
case 3:
$sql = 'SELECT a, b, d FROM t';
break;
case 4:
$sql = 'SELECT d FROM t';
break;
}

$result = mysql_query($sql);
// Get the result from DB with mysql_fetch_array() for example
}
}

Expected result:

Result of columns a and b from table t in first child
Result of column c from table s in second child
Result of column x from table s in third child
Result of columns a, b and d from table t in fourth child
Result of column d from table t in fifth child

Actual result:
--
For example (some worst case):

Nothing in first child
Result of column x from table s in second child
Result of column c from table s in third child
Result of columns a and b from table t in fourth child
Result of column d from table t in fifth child





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



#45595 [NEW]: ArrayObject::STD_PROP_LIST does not behave as documented with foreach

2008-07-22 Thread robin_fernandes at uk dot ibm dot com
From: robin_fernandes at uk dot ibm dot com
Operating system: Windows
PHP version:  5.2CVS-2008-07-22 (snap)
PHP Bug Type: SPL related
Bug description:  ArrayObject::STD_PROP_LIST does not behave as documented with 
foreach

Description:

The SPL documentation states that if the ArrayObject::STD_PROP_LIST  flag
is set on an ArrayObject instance:

  "Properties of the object have their normal functionality when accessed
as list (var_dump, foreach, etc.)"

(see
http://www.php.net/~helly/php/ext/spl/classArrayObject.html#daebe26f8478746da33c266a730714a9
)

This flag does affect var_dump(), but it seems to have no impact on
foreach. See reproduce code.

I'm not sure whether this is a functional problem or a documentation
problem.

Reproduce code:
---
p1 = 1;
$ao->p2 = 2;
$ao->p3 = 3;

echo "\nGet property list with var_dump:\n";
var_dump($ao);

echo "\nGet property list with foreach:\n";
foreach ($ao as $key=>$value) {
echo "  $key=>$value\n";
}
?>

Expected result:

Create instance of ArrayObject and add some normal properties...

Get property list with var_dump:
object(ArrayObject)#1 (3) {
  ["p1"]=>
  int(1)
  ["p2"]=>
  int(2)
  ["p3"]=>
  int(3)
}

Get property list with foreach:
  p1=>1
  p2=>2
  p3=>3

Actual result:
--
Create instance of ArrayObject and add some normal properties...

Get property list with var_dump:
object(ArrayObject)#1 (3) {
  ["p1"]=>
  int(1)
  ["p2"]=>
  int(2)
  ["p3"]=>
  int(3)
}

Get property list with foreach:
  0=>x
  1=>y
  2=>z

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



#43261 [Asn->Csd]: Use ^ as escape char for windows escapeshellcmd

2008-07-22 Thread scottmac
 ID:   43261
 Updated by:   [EMAIL PROTECTED]
 Reported By:  RQuadling at GMail dot com
-Status:   Assigned
+Status:   Closed
 Bug Type: Program Execution
 Operating System: Windows XP SP2
 PHP Version:  5.3CVS-2007-11-12 (snap)
 Assigned To:  scottmac
 New Comment:

This bug has been fixed in CVS.

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

Test added for this now.


Previous Comments:


[2008-06-10 12:10:08] [EMAIL PROTECTED]

Assigned to Scott, needs more tests cases and explanation (as it may
break a lot of scripts).



[2008-06-10 10:20:14] [EMAIL PROTECTED]

Actually Scott fixed this without marking it as fixed =)



[2008-06-10 10:12:54] [EMAIL PROTECTED]

Well if nobody else wanna apply it, then Ill take it =)



[2008-05-30 09:35:31] RQuadling at GMail dot com

Gee. Even with a patch, how do I get anyone to pay any attention!?



[2007-11-12 13:39:29] RQuadling at GMail dot com

Description:

The windows version of escapeshellcmd replaces any of the special
characters with a space, whereas, on other platforms it escapes them.

There is a valid escape character for windows. It is the ^ character.

Taking the current set of type-able characters from exec.c, the
following is a proof of the ^ working ...

2007/11/12 13:22:42 V:\PHP\PHP5>echo foo ^' bar
foo ' bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^" bar
foo " bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^# bar
foo # bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^$ bar
foo $ bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^% bar
foo % bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^& bar
foo & bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^( bar
foo ( bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^) bar
foo ) bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^* bar
foo * bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^; bar
foo ; bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^? bar
foo ? bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^[ bar
foo [ bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^\ bar
foo \ bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^] bar
foo ] bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^^ bar
foo ^ bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^` bar
foo ` bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^{ bar
foo { bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^| bar
foo | bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^} bar
foo } bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^~ bar
foo ~ bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^< bar
foo < bar

2007/11/12 13:22:43 V:\PHP\PHP5>echo foo ^> bar
foo > bar

I can't easily emulate 0xA0 and 0xFF in this test.


I've included a patch also ...

Index: exec.c
===
RCS file: /repository/php-src/ext/standard/exec.c,v
retrieving revision 1.125
diff -u -r1.125 exec.c
--- exec.c  5 Nov 2007 14:06:19 -   1.125
+++ exec.c  12 Nov 2007 13:13:09 -
@@ -291,13 +291,12 @@
case '\\':
case '\x0A': /* excluding these two */
case '\xFF':
-#ifdef PHP_WIN32
-   /* since Windows does not allow us to escape these 
chars, just
remove them */
case '%':
-   cmd[y++] = ' ';
-   break;
-#endif
+#ifdef PHP_WIN32
+   cmd[y++] = '^';
+#else
cmd[y++] = '\\';
+#endif
/* fall-through */
default:
cmd[y++] = str[x];



http://rquadling.php1h.com/exec.c.patch.txt

Reproduce code:
---
php -r "exec(escapeshellcmd('echo foo | bar'), $a, $b); var_dump($a,
$b);"


Expected result:

array(1) {
  [0]=>
  string(10) "foo ^| bar"
}
int(0)

Actual result:
--
array(1) {
  [0]=>
  string(9) "foo   bar"
}
int(0)





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



#43896 [Ctl->Opn]: htmlspecialchars returns empty string on invalid unicode sequence

2008-07-22 Thread moriyoshi
 ID:   43896
 Updated by:   [EMAIL PROTECTED]
 Reported By:  arnaud dot lb at gmail dot com
-Status:   Critical
+Status:   Open
 Bug Type: Strings related
 Operating System: *
 PHP Version:  5.2CVS, 5.3CVS (2008-07-15)


Previous Comments:


[2008-07-18 00:10:45] [EMAIL PROTECTED]

I even don't think this is a valid bug in the first place. You passed a

string that is encoded in ISO-8859-15 to htmlspecialchars() while 
specifying UTF-8 to force the string to be treated as "UTF-8". One 
should never depend on the past wrond behaviour with which invalid byte

sequences pass through. Besides, you can always work around it by
giving 
ISO-8859-15 to the third argument.







[2008-06-27 17:32:43] sillyxone at yaoo dot com

  is also affected in 5.2, for example:

$str = 'Hello' . chr(160) . 'there';
print(htmlentities($str, ENT_COMPAT, 'UTF-8'));

Instead of printing "Hello there", it prints nothing (empty string).
The same for htmlspecialchars().

Both functions work fine in 5.1



[2008-05-05 21:00:37] heurika at gmail dot com

Hi,
I've got the same Bug, posted on #43740.
Please fix it.

Thanks!



[2008-02-17 13:25:22] andreas dot ravnestad at gmail dot com

This seems to be breaking PEAR::Text_Wiki completely when using UTF-8:
http://pear.php.net/bugs/bug.php?id=13136



[2008-01-24 20:51:11] tallyce at gmail dot com

See also bugs 43294 and 43549 which seem to be the same thing.

This is really starting to bite now. Please can this be fixed, or
suggest how we can reliably process incoming user data in UTF8 given
this behaviour change!



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/43896

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



#45594 [NEW]: json_encode looses accentuated characters

2008-07-22 Thread neonira at gmail dot com
From: neonira at gmail dot com
Operating system: windows XP
PHP version:  5.2.6
PHP Bug Type: JSON related
Bug description:  json_encode looses accentuated characters

Description:

I checked that the file encoding character set for the php source file is
UTF-8. So it means, I provide a real UTF-8 entry, and I don't need to use
ut8_encode. 

It seems that accentuated caracters are truncated or not well managed
while json-encoding a string.



Reproduce code:
---
link = "http://www.neonira.com";;
 $this->str = "chaîne avec caractères accentués ... ";
 $this->arr = array(1, 3, "lala", "123", array ( 'a', 'b', 'c'),
134);
  }
}

$c = new CT();
$c->document();
echo json_encode($c);

?>

Expected result:

shell>php ../php/ct.php
{"link":"http:\/\/www.neonira.com","str":"chaîne avec caractères accentués
... ","arr":[1,3,"lala","123",["a","b","c"],134]}shell>

Actual result:
--
shell>{107}php ../php/ct.php
{"link":"http:\/\/www.neonira.com","str":"cha","arr":[1,3,"lala","123",["a","b","c"],134]}shell>


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



#45592 [Opn]: E_STRICT-warnings throws HTTP 500 error when display_errors is off

2008-07-22 Thread andy at boeckler dot org
 ID:   45592
 User updated by:  andy at boeckler dot org
-Summary:  E_STRICT-warnings throws HTTP 500 error when
   display_errors is off w/o ob_flush
 Reported By:  andy at boeckler dot org
 Status:   Open
 Bug Type: Output Control
 Operating System: Linux
 PHP Version:  5.2.6
 New Comment:

Update:
ob_flush() doesn't change anything ...
I accidentally tested it with display_errors=ON


Previous Comments:


[2008-07-22 15:13:17] andy at boeckler dot org

Description:

I'm getting Ajax-Request-Failures since PHP5 throws HTTP-500 Errors
back.
This was not the case before upgrading from PHP4.

This is annoying:
* E_STRICT are filtered out
* when display_errors is ON, the request is OK!
* display_errors ON is no option on a productionserver

It only works, when ob_flush() is called before exit() (see
staticFunc2)

Reproduce code:
---


Expected result:

HTTP 200

Actual result:
--
HTTP 500, w/o ob_flush() when display_errors is off
HTTP 200, w/o ob_flush() when display_errors is ON
HTTP 200, with ob_flush()





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



#45593 [NEW]: change the way 'implode' handles NULL values

2008-07-22 Thread getmequick at gmail dot com
From: getmequick at gmail dot com
Operating system: Win XP
PHP version:  5.2.6
PHP Bug Type: Feature/Change Request
Bug description:  change the way 'implode' handles NULL values

Description:

I'd like to know if it's reasonable to have 'implode' function do not
concatenate 'null/false' values into resulting string.

like it does 'http_build_query' (http://php.net/http_build_query)



Reproduce code:
---


Expected result:

dir1\dir2\dir3

Actual result:
--
dir1\dir2\\dir3

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



#45592 [NEW]: E_STRICT-warnings throws HTTP 500 error when display_errors is off w/o ob_flush

2008-07-22 Thread andy at boeckler dot org
From: andy at boeckler dot org
Operating system: Linux
PHP version:  5.2.6
PHP Bug Type: Output Control
Bug description:  E_STRICT-warnings throws HTTP 500 error when display_errors 
is off w/o ob_flush

Description:

I'm getting Ajax-Request-Failures since PHP5 throws HTTP-500 Errors back.
This was not the case before upgrading from PHP4.

This is annoying:
* E_STRICT are filtered out
* when display_errors is ON, the request is OK!
* display_errors ON is no option on a productionserver

It only works, when ob_flush() is called before exit() (see staticFunc2)

Reproduce code:
---


Expected result:

HTTP 200

Actual result:
--
HTTP 500, w/o ob_flush() when display_errors is off
HTTP 200, w/o ob_flush() when display_errors is ON
HTTP 200, with ob_flush()

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



#45563 [Bgs]: json_decode fails on json representing javascript objects

2008-07-22 Thread coyote4til7 at gmail dot com
 ID:   45563
 User updated by:  coyote4til7 at gmail dot com
 Reported By:  coyote4til7 at gmail dot com
 Status:   Bogus
 Bug Type: JSON related
 Operating System: Linux
 PHP Version:  5.2.6
 New Comment:

Jani, please read the definition of string in the spec.  Strings do not
have to be quoted for JSON.  That includes member (names).

Since JSON can be and is parsed via Javascript's eval (in fact that was
the method everyone used in the beginning and that is still used in
certain circumstances) and JavaScript's spec specifies that object names
are _not_ to be quoted, php's code can handle JSON that's coded properly
to make sure it doesn't blow up a strictly implemented JavaScript
interpreter.

So, let's see if I can summarize.  PHP's JSON support isn't about
JavaScript and so it doesn't support a major real-world use case.  So,
the JSON support in PHP is a fairly masturbatory exercise, no?


Previous Comments:


[2008-07-22 14:04:35] [EMAIL PROTECTED]

Note: This is about JSON, it's not about Javascript.



[2008-07-22 14:03:46] [EMAIL PROTECTED]

Actually you're wrong. From the RFC 4627:

object = begin-object [ member *( value-separator member ) ]
end-object
member = string name-separator value
string = quotation-mark *char quotation-mark



[2008-07-19 13:00:23] coyote4til7 at gmail dot com

Description:

When you encode a proper javascript object as json and then use the
json_decode function, it fails.

The keys in Javascript objects are _not_ supposed to be quoted.  If
you're going to store a json-encoded object (say in a database) and then
reuse it later in javascript, quoting the keys so that php's json_decode
function works means that you're counting on the browser's javascript to
support something that is not supported by the javascript specification.

Reproduce code:
---
// In javascript, we have an object:
// var obj = { parent_id:-1,label:"label" };
//
// In javascript, the keys for objects are _not_ quoted by 
// single or double quotes.  So, if we're going to properly encode
// this to later reuse it in javascript, we get this sent to php:
$json = '[{parent_id:-1,label:"label"}]';

// Let's try to convert it:
var_dump(json_decode($json, true));

Expected result:

{ ["parent_id"]=>  int(-1) ["label"]=>  string(5) "label" }

Actual result:
--
NULL





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



#45591 [NEW]: Bus error on file_get_contents

2008-07-22 Thread rommer at active dot by
From: rommer at active dot by
Operating system: linux-2.6.x i386
PHP version:  5.2CVS-2008-07-22 (snap)
PHP Bug Type: Reproducible crash
Bug description:  Bus error on file_get_contents

Description:

"Bus error" calling file_get_contents

Reproduce code:
---


Expected result:

nothing

Actual result:
--
"Bus error"

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



#45590 [NEW]: pcntl_fork() with MySQL queries

2008-07-22 Thread alan dot blotz at students dot uni-mainz dot de
From: alan dot blotz at students dot uni-mainz dot de
Operating system: Debian Lenny
PHP version:  5.2.6
PHP Bug Type: MySQL related
Bug description:  pcntl_fork() with MySQL queries

Description:

Already a long time ago the bug http://bugs.php.net/bug.php?id=38228 was
active, but I experienced some problems with the pcntl_fork() function
today. I already fixed the problem with multiple children connecting to the
MySQL server by using mysql_connect(..., true) or mysql_pconnect() (the
latter I'm using right now). My problem is, that with any of these methods
I'm partly getting wrong results to queries (see code). This really NOT
happening always, just sometimes when you don't expect it.

I can't post the original code due to copyrights, but the example below
should give you an idea of what is happening. I'm working with multiple
children in my application (executed as CLI), at least five at a time. Is
it perhaps a memory problem of PHP and / or MySQL?


Alan

Reproduce code:
---
// Queries for five children
for ($i = 0; $i < 5; $i++) {

// If I am the child
if (!pcntl_fork()) {

switch ($i) {

case 0:
$sql = 'SELECT a, b FROM t';
break;
case 1:
$sql = 'SELECT c FROM s';
break;
case 2:
$sql = 'SELECT x FROM s';
break;
case 3:
$sql = 'SELECT a, b, d FROM t';
break;
case 4:
$sql = 'SELECT d FROM t';
break;
}

$result = mysql_query($sql);
// Get the result from DB with mysql_fetch_array() for example
}
}

Expected result:

Result of columns a and b from table t in first child
Result of column c from table s in second child
Result of column x from table s in third child
Result of columns a, b and d from table t in fourth child
Result of column d from table t in fifth child

Actual result:
--
For example (some worst case):

Nothing in first child
Result of column x from table s in second child
Result of column c from table s in third child
Result of columns a and b from table t in fourth child
Result of column d from table t in fifth child

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



#41997 [Fbk]: pdo_mysql: stored procedure call returning single rowset blocks future queries

2008-07-22 Thread uw
 ID:   41997
 Updated by:   [EMAIL PROTECTED]
 Reported By:  nitel_defect at yahoo dot com
 Status:   Feedback
 Bug Type: PDO related
 Operating System: Windows XP SP2
 PHP Version:  5.2.3
 Assigned To:  johannes
 New Comment:

Please make sure that you try this with PHP 5.3+ and mysqlnd
(--with-pdo-mysql=mysqlnd , default). It might not work when using the
mysqlclient library (libmysql, --with-pdo-mysql=/path/to/mysql_config)


Previous Comments:


[2008-07-22 14:38:17] [EMAIL PROTECTED]

Please try using this CVS snapshot:

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

For Windows (installer):

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





[2008-05-22 17:32:37] [EMAIL PROTECTED]

The next PDO_MYSQLND release should fix this



[2008-01-24 11:46:34] ben at stickyeyes dot com

Just to add to this bug, I too experience this problem when trying to
execute two stored procedures, one after the other. 

Unfortunately, the only work around I could get working, was to create
a new PDO object for each query (attempting to clone an existing PDO
object caused Apache to crash, but thats another bug for another
day...)

Sucks, but it works.

Apache/2.2.4 (Win32) PHP/5.2.3
PDO Driver for MySQL, client library version5.0.37
MySQL 5.1.22



[2008-01-22 13:28:59] [EMAIL PROTECTED]

Reclassified: mysql -> pdo



[2007-08-21 00:08:52] marpiotr at gmail dot com

i seem to have the same problem on 5.1.6 on Fedora Core 6



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/41997

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



#45581 [Com]: htmlspecialchars() double encoding &#x hex items

2008-07-22 Thread funky2step at googlemail dot com
 ID:   45581
 Comment by:   funky2step at googlemail dot com
 Reported By:  funky2step at gmail dot com
 Status:   Verified
 Bug Type: Strings related
 Operating System: Red Hat Enterprise Linux ES
 PHP Version:  5.2.6
 New Comment:

Thanks for the prompt reply. I understood though that this function
with double encode arg set to false would not act on _any_ existing html
entities.
Is there a reason why it does not recognize these codes, or is it an
oversight/bug?


Previous Comments:


[2008-07-21 16:01:23] [EMAIL PROTECTED]

It's just that the function does not understand the hex entities. :)



[2008-07-21 14:21:11] funky2step at gmail dot com

obviously that should have been $out = htmlspecialchars($str,
ENT_COMPAT, 'UTF-8', FALSE);
:)



[2008-07-21 14:14:01] funky2step at gmail dot com

Description:

Trying to use htmlspecialchars() on a string containing &#xHEX;
characters e.g. £
With double encode set to false, it still converts the & to &

Reproduce code:
---
$str = "£ one & two";
$out = htmlspecialchars($content, ENT_COMPAT, 'UTF-8', FALSE);
echo $out;

Expected result:

£ one & two

Actual result:
--
£ one & two





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



#42499 [Asn->Fbk]: PDO_MYSQL: multi-statement execution via PDO::exec() makes connection unusable

2008-07-22 Thread uw
 ID:   42499
 Updated by:   [EMAIL PROTECTED]
 Reported By:  suhachov at gmail dot com
-Status:   Assigned
+Status:   Feedback
 Bug Type: PDO related
 Operating System: FC
 PHP Version:  5.2.4
 Assigned To:  johannes
 New Comment:

Please try using this CVS snapshot:

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

For Windows (installer):

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

Please make sure that you try this with PHP 5.3+ and mysqlnd
(--with-pdo-mysql=mysqlnd , default). It might not work when using the
mysqlclient library (libmysql, --with-pdo-mysql=/path/to/mysql_config)


Previous Comments:


[2008-05-22 19:53:27] [EMAIL PROTECTED]

Should be fixed with the next release of PDO_MYSQLND



[2008-05-08 14:58:33] [EMAIL PROTECTED]

See also http://pecl.php.net/bugs/bug.php?id=7433



[2008-04-29 14:43:34] kingoleg at mail dot ru

Hi, All

Is there any solution for this?



[2008-04-05 21:06:13] mgrdinic at sledxchange dot com

Any movement here?



[2007-09-04 14:45:46] [EMAIL PROTECTED]

Andrey, can you check this out please. (or reassing to whoever is
supposed to be maintaining ext/pdo_mysql :)




The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/42499

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



#41997 [Opn->Fbk]: pdo_mysql: stored procedure call returning single rowset blocks future queries

2008-07-22 Thread uw
 ID:   41997
 Updated by:   [EMAIL PROTECTED]
 Reported By:  nitel_defect at yahoo dot com
-Status:   Open
+Status:   Feedback
 Bug Type: PDO related
 Operating System: Windows XP SP2
 PHP Version:  5.2.3
 Assigned To:  johannes
 New Comment:

Please try using this CVS snapshot:

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

For Windows (installer):

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




Previous Comments:


[2008-05-22 17:32:37] [EMAIL PROTECTED]

The next PDO_MYSQLND release should fix this



[2008-01-24 11:46:34] ben at stickyeyes dot com

Just to add to this bug, I too experience this problem when trying to
execute two stored procedures, one after the other. 

Unfortunately, the only work around I could get working, was to create
a new PDO object for each query (attempting to clone an existing PDO
object caused Apache to crash, but thats another bug for another
day...)

Sucks, but it works.

Apache/2.2.4 (Win32) PHP/5.2.3
PDO Driver for MySQL, client library version5.0.37
MySQL 5.1.22



[2008-01-22 13:28:59] [EMAIL PROTECTED]

Reclassified: mysql -> pdo



[2007-08-21 00:08:52] marpiotr at gmail dot com

i seem to have the same problem on 5.1.6 on Fedora Core 6



[2007-07-16 18:06:49] nitel_defect at yahoo dot com

http://www.kpsol.ro/php_pdo_mysql.dll



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/41997

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



#44246 [Asn->Csd]: closedir() accepts a file resource opened by fopen()

2008-07-22 Thread felipe
 ID:   44246
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Assigned
+Status:   Closed
 Bug Type: Directory function related
 Operating System: Windows XP
 PHP Version:  5.2CVS-2008-02-25 (CVS)
 Assigned To:  felipe
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2008-02-25 16:55:39] [EMAIL PROTECTED]

Description:

closedir() will accept a file resource opened by fopen() as the
$directory argument. In the documentation for closedir() it says the
following: "The stream must have previously been opened by opendir()".
It seems that the resource type is not being checked correctly. 
A directory opened with opendir() can also be passed to fclose()
without an error message being generated.

Reproduce code:
---


Expected result:

resource(5) of type (stream)

Warning: closedir(): supplied argument is not a valid Directory
resource in ...
resource(5) of type (stream)
resource(6) of type (stream)

Warning: fclose(): supplied argument is not a valid stream resource in
...
bool(false)
resource(6) of type (stream)

Actual result:
--
resource(5) of type (stream)
resource(5) of type (Unknown)
resource(6) of type (stream)
bool(true)
resource(6) of type (stream)






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



#45066 [Opn]: Cannot compile a working php with mysql and mysqli

2008-07-22 Thread dirk at bean-it dot nl
 ID:   45066
 User updated by:  dirk at bean-it dot nl
 Reported By:  dirk at bean-it dot nl
 Status:   Open
 Bug Type: MySQL related
 Operating System: Debian 4.0 / x86_64
 PHP Version:  5.2.6
 New Comment:

mysqlnd is yet to be released for production use... So for now, that
seems not to be the way.

I'll upgrade the mysql libs on a test machine after my vacation (after
august 5th, that is). I'll post my findings here.

Thanks for looking in to this!

Cheers,

Dirk


Previous Comments:


[2008-07-21 18:16:20] [EMAIL PROTECTED]

Which means that one will be better served with mysqlnd?



[2008-07-17 23:09:21] [EMAIL PROTECTED]

By the looks of the valgrind output, IMO, this is some bug in the mysql
lib. Try google for __lll_mutex_lock_wait and you get plenty of hits
pointing to discussion forums. Corrupted heap, -lpthread vs -pthread,
etc. among the possible problems..



[2008-07-17 08:55:48] dirk at bean-it dot nl

Yes, and I was wrong... :)

In my opinion, bug#42625 went the wrong way (specially the last few
comments), so it would be clearer to start a new bugreport...



[2008-07-17 08:50:57] [EMAIL PROTECTED]

Ooops, it was you :)



[2008-07-17 08:49:40] [EMAIL PROTECTED]

Dirk,
I decided to look with Google for something similar and Bug#42625
appeared. The same problem, the same distro (Debian), the same version
of MySQL (5.0.32). The reported said he updated to some higher version
and the problem disappeared. Could this be the cause?

Best,
Andrey



The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/45066

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



#45563 [Bgs]: json_decode fails on json representing javascript objects

2008-07-22 Thread jani
 ID:   45563
 Updated by:   [EMAIL PROTECTED]
 Reported By:  coyote4til7 at gmail dot com
 Status:   Bogus
 Bug Type: JSON related
 Operating System: Linux
 PHP Version:  5.2.6
 New Comment:

Note: This is about JSON, it's not about Javascript.


Previous Comments:


[2008-07-22 14:03:46] [EMAIL PROTECTED]

Actually you're wrong. From the RFC 4627:

object = begin-object [ member *( value-separator member ) ]
end-object
member = string name-separator value
string = quotation-mark *char quotation-mark



[2008-07-19 13:00:23] coyote4til7 at gmail dot com

Description:

When you encode a proper javascript object as json and then use the
json_decode function, it fails.

The keys in Javascript objects are _not_ supposed to be quoted.  If
you're going to store a json-encoded object (say in a database) and then
reuse it later in javascript, quoting the keys so that php's json_decode
function works means that you're counting on the browser's javascript to
support something that is not supported by the javascript specification.

Reproduce code:
---
// In javascript, we have an object:
// var obj = { parent_id:-1,label:"label" };
//
// In javascript, the keys for objects are _not_ quoted by 
// single or double quotes.  So, if we're going to properly encode
// this to later reuse it in javascript, we get this sent to php:
$json = '[{parent_id:-1,label:"label"}]';

// Let's try to convert it:
var_dump(json_decode($json, true));

Expected result:

{ ["parent_id"]=>  int(-1) ["label"]=>  string(5) "label" }

Actual result:
--
NULL





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



#45563 [Opn->Bgs]: json_decode fails on json representing javascript objects

2008-07-22 Thread jani
 ID:   45563
 Updated by:   [EMAIL PROTECTED]
 Reported By:  coyote4til7 at gmail dot com
-Status:   Open
+Status:   Bogus
 Bug Type: JSON related
 Operating System: Linux
 PHP Version:  5.2.6
 New Comment:

Actually you're wrong. From the RFC 4627:

object = begin-object [ member *( value-separator member ) ]
end-object
member = string name-separator value
string = quotation-mark *char quotation-mark


Previous Comments:


[2008-07-19 13:00:23] coyote4til7 at gmail dot com

Description:

When you encode a proper javascript object as json and then use the
json_decode function, it fails.

The keys in Javascript objects are _not_ supposed to be quoted.  If
you're going to store a json-encoded object (say in a database) and then
reuse it later in javascript, quoting the keys so that php's json_decode
function works means that you're counting on the browser's javascript to
support something that is not supported by the javascript specification.

Reproduce code:
---
// In javascript, we have an object:
// var obj = { parent_id:-1,label:"label" };
//
// In javascript, the keys for objects are _not_ quoted by 
// single or double quotes.  So, if we're going to properly encode
// this to later reuse it in javascript, we get this sent to php:
$json = '[{parent_id:-1,label:"label"}]';

// Let's try to convert it:
var_dump(json_decode($json, true));

Expected result:

{ ["parent_id"]=>  int(-1) ["label"]=>  string(5) "label" }

Actual result:
--
NULL





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



#44459 [Fbk->Opn]: sybase_fetch_result not returning column_source

2008-07-22 Thread clark dot ryan at gmail dot com
 ID:   44459
 User updated by:  clark dot ryan at gmail dot com
 Reported By:  clark dot ryan at gmail dot com
-Status:   Feedback
+Status:   Open
 Bug Type: Sybase (dblib) related
 Operating System: Windows XP
 PHP Version:  5.2.5
 New Comment:

As far as I know I am already using sybase_ct;

extension=php_sybase_ct.dll

That is from my php.ini, un-commented.


Previous Comments:


[2008-07-21 12:08:28] [EMAIL PROTECTED]

Can you try with sybase_ct, ext/sybase is dead now (5.3+) and only
sybase_ct remains in php and is actively maintained.



[2008-03-25 11:04:27] [EMAIL PROTECTED]

It's returning a empty string, and this ever will occur with the actual
code.



[2008-03-17 20:26:50] clark dot ryan at gmail dot com

Description:

sybase_fetch_field is consistently returning me a NULL value for
column_source.

Reproduce code:
---
$conn = @sybase_pconnect('server','user','pass');
$query = "SELECT * FROM Products WHERE productID = 1";
$rs = sybase_query($query);
$row = sybase_fetch_field($rs);

echo '';
print_r($row);
echo '';

Expected result:

stdClass Object
(
[name] => productID
[max_length] => 11
[column_source] => 'Products'
[numeric] => 1
[type] => int
)

Actual result:
--
stdClass Object
(
[name] => productID
[max_length] => 11
[column_source] => 
[numeric] => 1
[type] => int
)





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



#45557 [Opn->Csd]: libxml visibility problem

2008-07-22 Thread rrichards
 ID:   45557
 Updated by:   [EMAIL PROTECTED]
 Reported By:  Fedora at FamilleCollet dot com
-Status:   Open
+Status:   Closed
 Bug Type: DOM XML related
 Operating System: Linux (Fedora 9)
 PHP Version:  5.3CVS-2008-07-18 (snap)
 New Comment:

This bug has been fixed in CVS.

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




Previous Comments:


[2008-07-18 18:38:25] Fedora at FamilleCollet dot com

Simple patch proposal witch solves this issue :

http://remi.fedorapeople.org/php-5.3.0-visibility.patch

Regards



[2008-07-18 18:33:43] Fedora at FamilleCollet dot com

Description:

After successful compilation xml extension doesn't load



Reproduce code:
---
php -v

Expected result:

PHP 5.3.0-dev (cli) (built: Jul 18 2008 20:20:22) 
Copyright (c) 1997-2008 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2008 Zend Technologies


Actual result:
--
# php -v
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib64/php/modules/dom.so' - /usr/lib64/php/modules/dom.so:
undefined symbol: php_libxml_node_free_resource in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib64/php/modules/xmlreader.so' -
/usr/lib64/php/modules/xmlreader.so: undefined symbol:
dom_node_class_entry in Unknown on line 0
PHP Warning:  PHP Startup: Unable to load dynamic library
'/usr/lib64/php/modules/xsl.so' - /usr/lib64/php/modules/xsl.so:
undefined symbol: dom_node_class_entry in Unknown on line 0
PHP 5.3.0-dev (cli) (built: Jul 18 2008 20:20:22) 
Copyright (c) 1997-2008 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2008 Zend Technologies






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



#44199 [Fbk->Bgs]: imap_fetch_overview fetch whole message

2008-07-22 Thread jani
 ID:   44199
 Updated by:   [EMAIL PROTECTED]
 Reported By:  evgenykireev at gmail dot com
-Status:   Feedback
+Status:   Bogus
 Bug Type: IMAP related
 Operating System: Windows XP
 PHP Version:  5.2.5
 Assigned To:  pajoye
 New Comment:

Yes, it's normal behaviour. It wouldn't be able to provide the
information otherwise.


Previous Comments:


[2008-07-21 21:48:45] [EMAIL PROTECTED]

Jani, does it happen with a recent imap lib as well on linux? like
2007a or b?



[2008-07-21 21:38:46] [EMAIL PROTECTED]

That's what c-client does behind the scenes. That's not any PHP bug.




[2008-02-21 08:03:20] evgenykireev at gmail dot com

Description:

I've noticed that imap_fetch_overview is very slow when I tried get
headers of big amount of messages. After some invistigations I've found
that imap_fetch_overview gets whole message(body and all attachments) -
not only headers. Why it is so? What do I need imap_fetchbody for?






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



#45121 [Bgs]: PHP Startup: Unable to load dynamic library 'c:/root/php/ext/php_openssl.dll'

2008-07-22 Thread chameleon_red_one at o2 dot pl
 ID:   45121
 User updated by:  chameleon_red_one at o2 dot pl
 Reported By:  chameleon_red_one at o2 dot pl
 Status:   Bogus
 Bug Type: IIS related
 Operating System: Windows XP
 PHP Version:  5.2.6
 New Comment:

As I was observed is it is not what is suspected "It certainly fails to
load the ssl DLLs."

When I use php-cgi.exe as *.php server it always work.
When I use php5isapi.dll as *.php server it always not work.

In both case I use exactly the same php.ini on the same computer :)

So if it such simple why in the first case it works and in the second
case not works - I am not understand from your description and spend a
lot of time and not found it explained yet?


Previous Comments:


[2008-07-21 12:25:42] [EMAIL PROTECTED]

it works but the extension is not loaded. It certainly fails to load
the ssl DLLs. I close it (bogus), please reopen it if you consider that
there is other problems involved.



[2008-05-28 21:37:07] chameleon_red_one at o2 dot pl

Description:

I have such problem that if I am running PHP over Windows XP IIS 5.1 it
is not able to load libeay32.dll and ssleay32.dll from c:/root/php/
directory.

It results that I have no ssl (dump from phpinfo()):
Registered Stream Socket Transports tcp, udp

In php_error.log is something like that:
PHP Warning:  PHP Startup: Unable to load dynamic library
'c:/root/php/ext/php_openssl.dll' - The operating system cannot run %1.

Strange is that if order IIS to execute php-cgi.exe from same path it
results:
Registered Stream Socket Transports tcp, udp, ssl, sslv3, sslv2, tls

So currently half of iis use php5isapi.dll and half php-cgi.exe.

Why such problem occurs is it bug or not - I was done about 100 of
searches and it is not help to find solution? I am very experience
programmer so I bet that it read in isapi mode ssleay32.dll from
c:\windows not c:\root\php but why cgi works?

Expected result:

I want to run *.php via php5isapi.dll on whole IIS 5.1 and not user
php-cgi.exe to have ssl protocol enable.

On phpinfo() I will be seeing:
Registered Stream Socket Transports tcp, udp, ssl, sslv3, sslv2, tls

Actual result:
--
Currently isapi not allow to load php_openssl.dll extenstion on iis
5.1

Registered Stream Socket Transports tcp, udp





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



#45588 [Opn->Bgs]: php5 crash in CLI mode

2008-07-22 Thread jani
 ID:   45588
 Updated by:   [EMAIL PROTECTED]
 Reported By:  alex at ai dot usurt dot ru
-Status:   Open
+Status:   Bogus
 Bug Type: Reproducible crash
 Operating System: FreeBSD 7.0
 PHP Version:  5.2.6
 New Comment:

First of all, get rid of any 3rd party patches (Suhosin!) and don't
load any 3rd party extensions in your php.ini. If you still can
reproduce this crash using latest CVS snapshot from
http://snaps.php.net/ you can reopen this.


Previous Comments:


[2008-07-22 06:26:06] alex at ai dot usurt dot ru

Description:

System: 
FreeBSD server 7.0-STABLE FreeBSD 7.0-STABLE #0: Tue Jun 10 12:41:05
YEKST 2008 [EMAIL PROTECTED]:/usr/obj/usr/src/sys/RELAY3  i386

PHP:
# pkg_info |grep php
php5-5.2.6  PHP Scripting Language

# php --version
PHP 5.2.6 with Suhosin-Patch 0.9.6.2 (cli) (built: Jun 27 2008
15:55:44)
Copyright (c) 1997-2008 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies
with Suhosin v0.9.24, Copyright (c) 2007, by SektionEins GmbH

Every launch of /usr/local/bin/php lead to php.core in current dir.

Example:

$ cd /tmp/111

$ ls -l /tmp/111
total 0

$ php --version
PHP 5.2.6 with Suhosin-Patch 0.9.6.2 (cli) (built: Jun 27 2008
15:55:44)
Copyright (c) 1997-2008 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies
with Suhosin v0.9.24, Copyright (c) 2007, by SektionEins GmbH
Segmentation fault: 11 (core dumped)

$ ls -l /tmp/111
total 2240
-rw---  1 root  wheel  2277376 22 июл 12:20
php.core

/usr/local/etc/php/extensions.ini:

extension=zlib.so
extension=pcre.so
extension=session.so
extension=mssql.so
extension=mysql.so
extension=pgsql.so
extension=gd.so
extension=iconv.so
extension=ldap.so
extension=imap.so
extension=mbstring.so
extension=suhosin.so







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



#44989 [Com]: 64bit Oracle RPMs still not supported by pdo-oci

2008-07-22 Thread noel dot rambaud at free dot fr
 ID:   44989
 Comment by:   noel dot rambaud at free dot fr
 Reported By:  stevec at engr dot oregonstate dot edu
 Status:   Open
 Bug Type: PDO related
 Operating System: Linux
 PHP Version:  5.2.6
 Assigned To:  sixd
 New Comment:

Create a link client-> client64 in directory
/usr/include/oracle/version_instantclientoracle

idem in /usr/lib/oracle/version_instantclientoracle


Previous Comments:


[2008-05-13 23:50:10] stevec at engr dot oregonstate dot edu

Description:

Bug #41941 addressed 64bit support for the --with-oci8 configure
option, but not the --with-pdo-oci option.  It still can't find the
include files.  

Reproduce code:
---
Using the Oracle provided 64bit InstantClient RPMs (currently using
11.1.0.1-1):

./configure --with-pdo-oci=instantclient,/usr/include,11.1.0 ...

Produces:

checking Oracle OCI support for PDO... yes
checking Oracle Install-Dir... instantclient,/usr/include,11.1.0
checking if that is sane... yes
checking for oci.h... configure: error: I'm too dumb to figure out
where the include dir is in your Instant Client install


Expected result:

Should pass that part and find the client64 libraries.

I've tried all sorts of paths (/usr to
/usr/include/oracle/11.1.0.1/client64) with no luck.






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



#41113 [Asn->WFx]: another complex memleak

2008-07-22 Thread tony2001
 ID:   41113
 Updated by:   [EMAIL PROTECTED]
 Reported By:  [EMAIL PROTECTED]
-Status:   Assigned
+Status:   Wont fix
 Bug Type: Scripting Engine problem
 Operating System: Linux
 PHP Version:  5CVS-2007-04-17 (CVS)
 Assigned To:  tony2001
 New Comment:

I guess so.


Previous Comments:


[2008-07-21 21:49:13] [EMAIL PROTECTED]

Isn't this "won't fix" then?



[2007-05-02 07:37:15] [EMAIL PROTECTED]

The problem is clear but unfixable.

$a[0] is compiled into ZEND_FETCH_DIM_R that increments reference count
of $a[0] this reference should be decremented back on $a[0] usage, but
because of exception this statement is never reached.





[2007-04-17 08:14:59] [EMAIL PROTECTED]

Description:

The code below causes two small memleaks.

Reproduce code:
---
prop[$a] = foo($undef2); //no leak
//$this->prop["aa"] = foo($undef2); //no leak
$this->prop[$a[0]] = foo($undef2); //leak
}
}

try {
foo();
} catch (Exception $e) {
var_dump($e->getMessage());
}
?>

Actual result:
--
==10584== 4 bytes in 1 blocks are indirectly lost in loss record 1 of
2
==10584==at 0x401C6CE: malloc (vg_replace_malloc.c:149)
==10584==by 0x82995DF: _emalloc (zend_alloc.c:2231)
==10584==by 0x8299885: _estrndup (zend_alloc.c:2353)
==10584==by 0x82B210F: _zval_copy_ctor_func (zend_variables.c:120)
==10584==by 0x831694C: _zval_copy_ctor (zend_variables.h:45)
==10584==by 0x82D9FAB:
ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER
(zend_vm_execute.h:3562)
==10584==by 0x82DA140: ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER
(zend_vm_execute.h:3609)
==10584==by 0x82D31F8: execute (zend_vm_execute.h:92)
==10584==by 0x82D371A: zend_do_fcall_common_helper_SPEC
(zend_vm_execute.h:234)
==10584==by 0x82D6614: ZEND_DO_FCALL_SPEC_CONST_HANDLER
(zend_vm_execute.h:1681)
==10584==by 0x82D31F8: execute (zend_vm_execute.h:92)
==10584==by 0x82B3E37: zend_execute_scripts (zend.c:1134)
==10584==by 0x826A9BC: php_execute_script (main.c:1790)
==10584==by 0x831A5B5: main (php_cli.c:1127)
==10584==
==10584==
==10584== 20 (16 direct, 4 indirect) bytes in 1 blocks are definitely
lost in loss record 2 of 2
==10584==at 0x401C6CE: malloc (vg_replace_malloc.c:149)
==10584==by 0x82995DF: _emalloc (zend_alloc.c:2231)
==10584==by 0x82D9F5D:
ZEND_ADD_ARRAY_ELEMENT_SPEC_CONST_UNUSED_HANDLER
(zend_vm_execute.h:3559)
==10584==by 0x82DA140: ZEND_INIT_ARRAY_SPEC_CONST_UNUSED_HANDLER
(zend_vm_execute.h:3609)
==10584==by 0x82D31F8: execute (zend_vm_execute.h:92)
==10584==by 0x82D371A: zend_do_fcall_common_helper_SPEC
(zend_vm_execute.h:234)
==10584==by 0x82D6614: ZEND_DO_FCALL_SPEC_CONST_HANDLER
(zend_vm_execute.h:1681)
==10584==by 0x82D31F8: execute (zend_vm_execute.h:92)
==10584==by 0x82B3E37: zend_execute_scripts (zend.c:1134)
==10584==by 0x826A9BC: php_execute_script (main.c:1790)
==10584==by 0x831A5B5: main (php_cli.c:1127)





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