#43321 [NEW]: Namespace inside a label
From: felipensp at gmail dot com Operating system: PHP version: 6CVS-2007-11-18 (snap) PHP Bug Type: Scripting Engine problem Bug description: Namespace inside a label Description: Is possible to use namespace declaration inside a label. Is this correct? And the error message could be changed, as 'use' and 'declare' (perhaps also 'label' declaration) statements can be used before him. Reproduce code: --- ?php foo: namespace foo::bar; Expected result: Fatal error: Namespace declaration statement has to be the very first statement in the script Actual result: -- No error -- Edit bug report at http://bugs.php.net/?id=43321edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43321r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43321r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43321r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43321r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43321r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43321r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43321r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43321r=needscript Try newer version:http://bugs.php.net/fix.php?id=43321r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43321r=support Expected behavior:http://bugs.php.net/fix.php?id=43321r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43321r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43321r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43321r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43321r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43321r=dst IIS Stability:http://bugs.php.net/fix.php?id=43321r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43321r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43321r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43321r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43321r=mysqlcfg
#41874 [Com]: Separate STDOUT and STDERR in exec functions
ID: 41874 Comment by: alexey dot kupershtokh at gmail dot com Reported By: ckeefer at us dot nomura dot com Status: Open Bug Type: Program Execution Operating System: Windows XP Pro SP2 PHP Version: 5.2CVS-2007-07-03 New Comment: Hello guys. All the symfony community seems suffer from this bug. I'm not sure whether this is exactly the same problem comparing to the bugstarter's, but symptoms are very similar. The following ssh.exe is taken from a cwRsync package. Sorry for using this exe, I just don't know any other that requires user input. Description: PHP =5.2.2 doesn't allow interaction with user for program executed by passthru/system/exec, where =5.2.1 do. Reproduce code: --- php.exe -n -r exec('ssh.exe dev.sibers.com'); Expected result: PHP 5.2.1: C:\Distrib\Development\PHP\PHP Switcher\5.2.1\phpphp.exe -n -r exec('ssh.exe dev.sibers.com'); The authenticity of host 'dev.sibers.com (89.251.97.196)' can't be established. RSA key fingerprint is XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX. Are you sure you want to continue connecting (yes/no)? PHP 5.2.2: C:\Distrib\Development\PHP\PHP Switcher\5.2.2\phpphp.exe -n -r exec('ssh.exe dev.sibers.com'); The authenticity of host 'dev.sibers.com (89.251.97.196)' can't be established. RSA key fingerprint is XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX. Are you sure you want to continue connecting (yes/no)? Actual result: -- For 5.2.1 is the same: C:\Distrib\Development\PHP\PHP Switcher\5.2.1\phpphp.exe -n -r exec('ssh.exe dev.sibers.com'); The authenticity of host 'dev.sibers.com (89.251.97.196)' can't be established. RSA key fingerprint is XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX:XX. Are you sure you want to continue connecting (yes/no)? 5.2.2: C:\Distrib\Development\PHP\PHP Switcher\5.2.2\phpphp.exe -n -r exec('ssh.exe dev.sibers.com'); and it hangs w/o any output... Typing 'yes' blindly doesn't help (C:\Documents and Settings\wicked\.ssh\known_hosts stays unmodified). Previous Comments: [2007-07-19 20:00:23] [EMAIL PROTECTED] As I'm not any win32 expert (nor really care about it) I'll deassign this and forget that change, perhaps someone else who know the win32 stuff picks this up. [2007-07-18 15:47:23] ckeefer at us dot nomura dot com I don't actually see how this is an improvement as output was only mixed if you don't redirect, which is expected. If I do something like php progname.php logfile.txt, I would previously redirect STDIN to the logfile as expected and stderr would still come to the console so I could monitor the program's progress. This is the usual behavior in shell programs, etc. This is how cmd line php was working through version 5.21. 5.22 on changed behavior in that from Win32, the STDERR disappears completely. If you can tell me where STDERR went and how to get to it from exec, I will happily do that. I have hundreds (if not thousands) of php scripts that do this. This new behavior breaks all of them. If I do php progname.php 21 logfile.txt, even if this works, I get mixed STDIN and STDERR output in the logfile.txt. This will force me to either stay at version 5.21 or earlier, or revise every script we have that currently uses the exec function. Again I ask: Did anything change with the compiler or other development tools used to create the Window Binary? Microsoft has been known to modify libraries in undocumented ways. Thanks Chip Keefer [2007-07-18 14:55:27] [EMAIL PROTECTED] Since this is actually improvement from previous behaviour where the output was mixed, I'm changing this to a FR. I'll look into adding an extra parameter to store STDERR in. In the meantime I suggest you use proc_open() or popen() which give you more control over these.. [2007-07-18 13:01:40] ckeefer at us dot nomura dot com Oddly, 5.2.2+ versions still work correctly with cygwin/bash 3.1 Using the same Win32 binary, not a Cygwin binary. To [EMAIL PROTECTED]: That is a good suggestion for just getting STDERR output and I use it often on Unix and Linux systems when I need, and don't care if outputs are mixed. I haven't tested if this construct works with W32. Unfortunately, I need STDIN and STDERR separate. I also have a question: Did the version of compiler or libraries used to compile the binary change? MS is notorious for making undocumented changes to their development tools. Thanks, Chip Keefer [2007-07-18 08:45:45] [EMAIL PROTECTED] This works fine with *nix (found from the user comments at http://www.php.net/manual/en/function.exec.php
#43322 [NEW]: $this[] not produces error
From: felipensp at gmail dot com Operating system: PHP version: 6CVS-2007-11-18 (snap) PHP Bug Type: Scripting Engine problem Bug description: $this[] not produces error Description: $this[] outside of class not produces error. Reproduce code: --- ?php class foo { public function __construct() { $this[] = 1; } } // Fatal error: Cannot re-assign $this // $this = new foo; // Fatal error: Using $this when not in object context // $this-a = new foo; // Fatal error: Cannot use object of type foo as array // new foo; $this[] = new stdClass; // no error Expected result: Fatal error: Using $this when not in object context Actual result: -- No error -- Edit bug report at http://bugs.php.net/?id=43322edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43322r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43322r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43322r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43322r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43322r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43322r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43322r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43322r=needscript Try newer version:http://bugs.php.net/fix.php?id=43322r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43322r=support Expected behavior:http://bugs.php.net/fix.php?id=43322r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43322r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43322r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43322r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43322r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43322r=dst IIS Stability:http://bugs.php.net/fix.php?id=43322r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43322r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43322r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43322r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43322r=mysqlcfg
#43323 [NEW]: Wrong count abstract methods
From: felipensp at gmail dot com Operating system: PHP version: 6CVS-2007-11-18 (snap) PHP Bug Type: Scripting Engine problem Bug description: Wrong count abstract methods Description: Wrong count abstract methods when name of method is same class name. When used the same code with namespace, the count is correct. Reproduce code: --- ?php // namespace foo; # The count is correct abstract class bar { abstract public function bar(); } class foo extends bar { } Expected result: Fatal error: Class foo contains 1 abstract methods and must therefore be declared abstract or implement the remaining methods (bar::bar) Actual result: -- Fatal error: Class foo contains 2 abstract methods and must therefore be declared abstract or implement the remaining methods (bar::bar, bar::bar) -- Edit bug report at http://bugs.php.net/?id=43323edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43323r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43323r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43323r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43323r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43323r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43323r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43323r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43323r=needscript Try newer version:http://bugs.php.net/fix.php?id=43323r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43323r=support Expected behavior:http://bugs.php.net/fix.php?id=43323r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43323r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43323r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43323r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43323r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43323r=dst IIS Stability:http://bugs.php.net/fix.php?id=43323r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43323r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43323r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43323r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43323r=mysqlcfg
#43316 [Asn-Bgs]: About the bug #42590
ID: 43316 Updated by: [EMAIL PROTECTED] Reported By: dagdamor at simps dot ru -Status: Assigned +Status: Bogus Bug Type:Strings related PHP Version: 5.2.5 Assigned To: iliaa 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 \v and \f are escape sequences since, well, ever. PHP due to a bug had simply failed to implement them before. Further more, if you are using heredoc or double quotes you should ALWAYS escape the \ if you want it to be rendered properly. Previous Comments: [2007-11-17 22:24:36] [EMAIL PROTECTED] Ilia, you propably should explain this..? :D [2007-11-17 01:28:00] dagdamor at simps dot ru Description: http://bugs.php.net/bug.php?id=42590 I don't understand the issue... since when \v and \f are escape sequences? According to the manual (http://www.php.net/manual/en/language.types.string.php), those are just regular character sequences, backslash followed with letter. -- Edit this bug report at http://bugs.php.net/?id=43316edit=1
#38245 [Asn-Bgs]: File Upload Problem When magic_quotes_gpc = On
ID: 38245 Updated by: [EMAIL PROTECTED] Reported By: david at orangegateos dot com -Status: Assigned +Status: Bogus Bug Type: *General Issues Operating System: Windows 2003 and IIS6.0 PHP Version: 5CVS-2006-07-31 (snap) Assigned To: iliaa New Comment: It is intentional behavior. The code already does basename before magic quotes are applied. However, if you fail to remove the \ char from the filename windows will treat it as a directory separator and thus will try to place the file inside a wrong directory should you attempt to write it. Previous Comments: [2007-07-04 17:01:25] [EMAIL PROTECTED] Ilia, this can't be intentional.. [2007-06-21 22:28:31] [EMAIL PROTECTED] Uhm, I think the filename should only escaped after applying basename(). I didn't look to the sources to check if that is possible, though. [2006-08-04 16:07:48] [EMAIL PROTECTED] 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 Actually upon further review it seems that this behavior is intended. The filename is supposed to contain just the filename, however on Win32 backslash (\) is considered to be a directory separator, at it foo\'bar.txt would actually be treated as directory foo containing file 'bar.txt. [2006-07-31 21:51:17] david at orangegateos dot com I did some rather extensive testing today with many different versions of PHP. I used Windows versions of PHP for my testing. Utilized versions of PHP 5 were from 5.0.0 to 5.1.4 and versions of PHP 4 from 4.1.0 to 4.4.2. The result I was looking for was a full, escaped filename to be output on the page (e.g. David\'s Image.jpg). Versions that gave the *desired* results were: 4.1.0, 4.1.1, 4.1.2, 4.2.0, 4.2.1, 4.2.3, 4.3.0, 4.3.1, 4.3.2, 4.3.3, 4.3.4, 4.3.5, 4.3.6, 4.3.7, 4.3.8, 4.3.9, 5.0.0, 5.0.1, and 5.0.2. Versions 4.3.10+ and 5.0.3+ all gave incorrect results. It is noted in the ChangeLog that this bug was fixed in PHP versions 4.3.11 and 5.0.4, but these versions still produce incorrect results. In the Handling File Uploads documentation notes section, some users report that there are some problems with this feature. The first occurrence of this is at http://us2.php.net/manual/en/features.file-upload.php#60024, and another appears at http://us2.php.net/manual/en/features.file-upload.php#64087. The documentation states that $_FILES['userfile']['name'] is the original name of the file on the client machine. Are Windows versions of PHP supposed to be chopping off the filename if magic_quotes_gpc is on, or is it supposed to return the full, escaped filename? [2006-07-28 21:42:14] david at orangegateos dot com I have just tried the linked version for Windows, and I continue to receive the same problem. I used the included php.ini-dist file, unmodified from the zip file. However, I do receive the full, escaped filename with 5.0.2, similiar to what you say you receive with the linked 5.2. This is on a Windows Server 2003 box with IIS6.0. 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/38245 -- Edit this bug report at http://bugs.php.net/?id=38245edit=1
#43311 [Asn-Bgs]: setcookie should not be able to set cookies larger than 4096 bytes
ID: 43311 Updated by: [EMAIL PROTECTED] Reported By: crrodriguez at suse dot de -Status: Assigned +Status: Bogus Bug Type: *General Issues Operating System: Irrelevant PHP Version: 5.3CVS-2007-11-16 (CVS) Assigned To: iliaa New Comment: While it would be absolutely trivial to add an artificial limit of 4K or any other arbitrary # as the maximum cookie length. This would not be correct and has a good chance of breaking existing applications. Previous Comments: [2007-11-16 12:38:30] [EMAIL PROTECTED] In my opinion it's up to the coder to decide what he allows to be put in cookies set. If he/she does't bother doing any filtering or such for and inserts blindly input data there, it's his/her fault.. [2007-11-16 09:54:58] yoy dot noneoff at dfgh dot net ie7 increased the number of cookies per domain from 20 to 50, like other browsers. so why not limiting php to set max 20 cookies per domain like NS mention? Netscape also follow these rfc if the client ignore part of the cookie it's not PHP concern. what if I built an application follow the rfc and php artificially limiting me? [2007-11-16 08:51:31] crrodriguez+php at suse dot de also imagine the following code setcookie (foo, $_GET['reallybigdata']) it can also exausts the PHP process or system memory(dependding on the memory limit)for no gain because the browser will truncate it anyway. [2007-11-16 08:23:38] judas dot iscariote at gmail dot com PHP implements the netscape spec, **not** the RFC one When a cookie larger than 4 kilobytes is encountered the cookie should be trimmed to fit, but the name should remain intact as long as it is less than 4 kilobytes Servers should not expect clients to be able to exceed these limits In the case of PHP, sending a cookie bigger than 4kb is useless because no browser will use it correctly, and truncating it without emitting any warning just makes debugging harder. [2007-11-16 08:17:45] yoy dot noneoff at dfgh dot net http://www.faqs.org/rfcs/rfc2109 http://www.faqs.org/rfcs/rfc2965 RFCS linked from the setcookie function docs ... * at least 300 cookies * at least 4096 bytes per cookie (as measured by the characters that comprise the cookie non-terminal in the syntax description of the Set-Cookie2 header, and as received in the Set-Cookie2 header) ... keyword:at least so basicly php should not limit cookie length, it up to the client/browser how to handle it. 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/43311 -- Edit this bug report at http://bugs.php.net/?id=43311edit=1
#42261 [Asn-Csd]: header wrong for date field
ID: 42261 Updated by: [EMAIL PROTECTED] Reported By: roberto at spadim dot com dot br -Status: Assigned +Status: Closed Bug Type: dBase related Operating System: any PHP Version: 5.2.4 Assigned To: iliaa 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: [2007-11-14 23:40:29] [EMAIL PROTECTED] Ilia, can you fix it in the other place too? (and another, and another? :) [2007-10-17 06:45:09] roberto at spadim dot com dot br =case 'L': =dbf-db_flen = 1; =break; should work for logic values (boolean) [2007-09-28 19:18:28] roberto at spadim dot com dot br hello, the same error occur now for logic data (boolean) [0] = Array ( [name] = SUSPENSO [type] = boolean [length] = 34817 = should be 1 [precision] = 0 [format] = %34817s [offset] = 1 ) [1] = Array ( [name] = COD_CAD [type] = number [length] = 9 [precision] = 0 : [2007-08-10 00:30:11] [EMAIL PROTECTED] 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. [2007-08-09 22:57:45] spadim at spadim dot com dot br this could be the same problem of bug #27470 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/42261 -- Edit this bug report at http://bugs.php.net/?id=42261edit=1
#43324 [NEW]: Label scope
From: felipensp at gmail dot com Operating system: PHP version: 6CVS-2007-11-18 (snap) PHP Bug Type: Scripting Engine problem Bug description: Label scope Description: Only occur error when inside a block. (e.g. if, empty block, ...) Reproduce code: --- ?php $i = 0; a: // No error class foo { } // Produces error // Fatal error: Cannot redeclare class foo /* { class foo { } } */ if ($i++ != 4) goto a; Expected result: Error ? Actual result: -- Error whenever declaring inside a block. -- Edit bug report at http://bugs.php.net/?id=43324edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43324r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43324r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43324r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43324r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43324r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43324r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43324r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43324r=needscript Try newer version:http://bugs.php.net/fix.php?id=43324r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43324r=support Expected behavior:http://bugs.php.net/fix.php?id=43324r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43324r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43324r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43324r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43324r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43324r=dst IIS Stability:http://bugs.php.net/fix.php?id=43324r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43324r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43324r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43324r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43324r=mysqlcfg
#43310 [Fbk-Csd]: crash with References and unset
ID: 43310 Updated by: [EMAIL PROTECTED] Reported By: commander at graphicore dot de -Status: Feedback +Status: Closed Bug Type: Reproducible crash Operating System: Linux, WinXp PHP Version: 5.2.5 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. This is working fine in 5.3dev, so considered fixed. Previous Comments: [2007-11-16 10:32:42] crrodriguez+php at suse dot de this is the deal 5_3 is fine 5_2 non-debug = Crashes 5_2 debug Starting program: /home/cristian/5.2/sapi/cli/php ../crash.php 4 objects are loaded Warning: array_keys(): The first argument should be an array in /home/cristian/crash.php on line 18 3 objects are loaded [Fri Nov 16 07:27:03 2007] Script: '../crash.php' /home/cristian/5.2/Zend/zend_vm_execute.h(405) : Freeing 0x0096A6A8 (24 bytes), script=../crash.php Last leak repeated 2 times [Fri Nov 16 07:27:03 2007] Script: '../crash.php' /home/cristian/5.2/Zend/zend_execute.c(1009) : Freeing 0x0096C890 (71 bytes), script=../crash.php /home/cristian/5.2/Zend/zend_hash.c(388) : Actual location (location was relayed) Last leak repeated 2 times [Fri Nov 16 07:27:03 2007] Script: '../crash.php' /home/cristian/5.2/Zend/zend_execute.c(1061) : Freeing 0x0096F748 (24 bytes), script=../crash.php Last leak repeated 1 time [Fri Nov 16 07:27:03 2007] Script: '../crash.php' /home/cristian/5.2/Zend/zend_execute.c(1065) : Freeing 0x0096F7B8 (72 bytes), script=../crash.php /home/cristian/5.2/Zend/zend_API.c(821) : Actual location (location was relayed) Last leak repeated 3 times [Fri Nov 16 07:27:03 2007] Script: '../crash.php' /home/cristian/5.2/Zend/zend_hash.c(247) : Freeing 0x0096FB38 (79 bytes), script=../crash.php === Total 13 memory leaks detected === [2007-11-16 00:51:03] [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. [2007-11-16 00:32:00] felipensp at gmail dot com Works fine in PHP 5.3.0-dev (cli) (built: Nov 15 2007 18:47:59) [2007-11-15 23:18:37] commander at graphicore dot de Description: The code crashes the Apache process immediately. The crash occurs with other functions(array_values, print_r, gettype, ...) instead of array_keys() as well. To avoid the crash delete the reference in Line 7 to copy the array that contains the references. That was intended anyway. However, it took hours to find the problem. A Runtime-Error or something like that would be nice. Systems: Linux(Ubuntu): Apache/2.2.4 PHP/5.2.3-1ubuntu6 Apache error.log: [Thu Nov 15 23:18:48 2007] [notice] child pid 2874 exit signal Segmentation fault (11) WinXp: Apache/2.2.3 (Win32) PHP Version 4.4.4 Apache error.log: [Thu Nov 15 23:43:43 2007] [notice] Parent: child process exited with status 3221225477 -- Restarting. best regards Reproduce code: --- ?php class aClass{ var $arr; function makeObjects($load){ for($i = 1; $load = $i; $i++){ $this-arr['objects'][$i] = new aClass(); $this-arr['objects'][$i]-arr = $this-arr;//copying $this-arr avoids the crash } echo count($this-arr['objects']).' objects are loaded'.\n; } } $root = new aClass(); $objects[0] = $root; $root-arr['objects'] = $objects; $load = 3; $root-makeObjects($load); unset($objects[$load]);//unset the last object array_keys($root-arr['objects']);//crash echo count($objects).' objects are loaded'; ? Expected result: 4 objects are loaded 3 objects are loaded Actual result: -- the process crashes, no warning, no error -- Edit this bug report at http://bugs.php.net/?id=43310edit=1
#43260 [Com]: DOM doesn't produce valid XHTML.
ID: 43260 Comment by: missingno at ifrance dot com Reported By: dhopkins at mutinydesign dot co dot uk Status: Assigned Bug Type: Feature/Change Request Operating System: Ubuntu Server PHP Version: 5.2CVS-2007-11-12 (snap) Assigned To: rrichards New Comment: In fact, there's already a constant (both in PHP libxml = 2.6.21) to drop the XML declaration, but it seems it can't be used in any of the save*() methods of the DOM extension. Definition of the PHP constant (LIBXML_NOXMLDECL): http://cvs.php.net/viewvc.cgi/php-src/ext/libxml/libxml.c?annotate=1.65#l630 Implementation of DOM's SaveXML (dom_document_savexml) http://cvs.php.net/viewvc.cgi/php-src/ext/dom/document.c?annotate=1.88#l1681 The LIBXML_NOXMLDECL can be used when loading XML data from a file or a string (see DOM Document's load()/loadXML()). Maybe this constant should also be available in the options passed to save()/saveXML(). However, you might be able to achieve the same effect by: - loading your HTML content in a DOMDocument, - loading a dummy XML file/string (such as html /, passing LIBXML_NOXMLDECL as an option to the load method) in a second DOMDocument (we will refer to it as the XML DOMDocument) - using importNode($node, TRUE) to deep-copy import the HTML content in the XML DOMDocument - use save()/saveXML() on the XML DOMDocument to dump the resulting tree I didn't test this workaround (yet), though. Also, please note that serving XML as HTML is often considered harmful for the Internet. There's also a lot of concerns regarding Appendix C of the XHTML 1.0 Spec (dealing with HTML-Compatible XHTML markup). Hope this helps Previous Comments: [2007-11-12 14:49:03] [EMAIL PROTECTED] IE6 isn't fully XHTML compliant and xml declaration is perfectly valid. Assigning to self as support for save options (including ability to suppress declaration) are currently in progress. Not yet fully integrated into DOM extension as this requires fairly recent libxml2 to work. [2007-11-12 13:22:27] dhopkins at mutinydesign dot co dot uk Description: This issue is similar to a similar one posted earlier ( http://bugs.php.net/bug.php?id=31130 ). Basically, I want to use the DOM functions to return valid XHTML - with trailing slashes - but the saveHTML method returns HTML 4.0 loose. As was pointed out in the above post, you can just use the saveXML method to return valid XHTML. However, there is a big problem with this. If you have a XHTML document that starts with the xml decleration ?xml?, Internet Explorer 6 doesn't read the HTML DTD. The result of which is a skewed document, various CSS attributes are not supported etc. You are basically trying to display a HTML document with an XML doctype. Currently, I am just trimming the xml decleration off the document, which I am sure you can appreciate is not a very good solution, but its the only option. Is it possible to add a feature that will return XML without the XML decleration? Or is this really something I need to take up with LibXML? There are quite a few people moaning about this issue, but so far no solutions has been provided. Reproduce code: --- $doc = new DomDocument(); $input = $doc-createElement('input'); $input-setAttribute('type', 'checkbox'); $input-setAttribute('checked', 'checked'); $doc-appendChild($input); echo $doc-saveXML(); Expected result: input type=checkbox checked=checked / Actual result: -- ?xml version=1.0 encoding=utf-8 standalone=yes? input type=checkbox checked / -- Edit this bug report at http://bugs.php.net/?id=43260edit=1
#43324 [Opn-Bgs]: Label scope
ID: 43324 Updated by: [EMAIL PROTECTED] Reported By: felipensp at gmail dot com -Status: Open +Status: Bogus Bug Type:Scripting Engine problem PHP Version: 6CVS-2007-11-18 (snap) 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 There is no label scope... Previous Comments: [2007-11-18 15:17:59] felipensp at gmail dot com Description: Only occur error when inside a block. (e.g. if, empty block, ...) Reproduce code: --- ?php $i = 0; a: // No error class foo { } // Produces error // Fatal error: Cannot redeclare class foo /* { class foo { } } */ if ($i++ != 4) goto a; Expected result: Error ? Actual result: -- Error whenever declaring inside a block. -- Edit this bug report at http://bugs.php.net/?id=43324edit=1
#43321 [Opn-Bgs]: Namespace inside a label
ID: 43321 Updated by: [EMAIL PROTECTED] Reported By: felipensp at gmail dot com -Status: Open +Status: Bogus Bug Type:Scripting Engine problem PHP Version: 6CVS-2007-11-18 (snap) 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 WHy would you need a label before it anywya? Previous Comments: [2007-11-18 11:30:02] felipensp at gmail dot com Description: Is possible to use namespace declaration inside a label. Is this correct? And the error message could be changed, as 'use' and 'declare' (perhaps also 'label' declaration) statements can be used before him. Reproduce code: --- ?php foo: namespace foo::bar; Expected result: Fatal error: Namespace declaration statement has to be the very first statement in the script Actual result: -- No error -- Edit this bug report at http://bugs.php.net/?id=43321edit=1
#43319 [Opn]: Serialization of objects with Serializable interface and circular references
ID: 43319 User updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Open Bug Type: Reproducible crash Operating System: Linux, Windows PHP Version: 5.2.5 New Comment: I don't know if this is the more apropriated solution for this problem. When you try without the use of interface, you have the same recursion, but no crash. Previous Comments: [2007-11-18 04:28:43] crrodriguez+php at suse dot de This causes infinite recursion,hence a crash.. I expect a very clear: zend_error(E_ERROR, Nesting level too deep - recursive dependency?); [2007-11-17 15:26:04] [EMAIL PROTECTED] Description: Apache crashes and CLI segfault when serializing objects which have circular references and implements the Serializable interface. Whitout the interface, the serialization and deserialization occurs without any problem. Reproduce code: --- ?php class A implements Serializable { private $b; public function setB($b) { $this-b = $b; } public function serialize() { return serialize($this-b); } public function unserialize($s) { $this-b = unserialize($s); } } class B { private $a; public function __construct($a) { $a-setB($this); $this-a = $a; } } $a = new A(); $b = new B($a); var_dump(serialize($b)); ? Expected result: The string of the serialized object. Actual result: -- Apache crash or cli segfault. -- Edit this bug report at http://bugs.php.net/?id=43319edit=1
#43260 [Com]: DOM doesn't produce valid XHTML.
ID: 43260 Comment by: missingno at ifrance dot com Reported By: dhopkins at mutinydesign dot co dot uk Status: Assigned Bug Type: Feature/Change Request Operating System: Ubuntu Server PHP Version: 5.2CVS-2007-11-12 (snap) Assigned To: rrichards New Comment: Yet another possible workaround (also untested): When you're done preparing your markup: - use DOMDocument-saveXML() to dump the tree to a string, - create another DOMDocument, use loadXML() with LIBXML_NOXMLDECL on that string - finally, dump this new DOMDocument's tree to a file/string using the usual save/saveXML methods. Previous Comments: [2007-11-18 17:31:40] missingno at ifrance dot com In fact, there's already a constant (both in PHP libxml = 2.6.21) to drop the XML declaration, but it seems it can't be used in any of the save*() methods of the DOM extension. Definition of the PHP constant (LIBXML_NOXMLDECL): http://cvs.php.net/viewvc.cgi/php-src/ext/libxml/libxml.c?annotate=1.65#l630 Implementation of DOM's SaveXML (dom_document_savexml) http://cvs.php.net/viewvc.cgi/php-src/ext/dom/document.c?annotate=1.88#l1681 The LIBXML_NOXMLDECL can be used when loading XML data from a file or a string (see DOM Document's load()/loadXML()). Maybe this constant should also be available in the options passed to save()/saveXML(). However, you might be able to achieve the same effect by: - loading your HTML content in a DOMDocument, - loading a dummy XML file/string (such as html /, passing LIBXML_NOXMLDECL as an option to the load method) in a second DOMDocument (we will refer to it as the XML DOMDocument) - using importNode($node, TRUE) to deep-copy import the HTML content in the XML DOMDocument - use save()/saveXML() on the XML DOMDocument to dump the resulting tree I didn't test this workaround (yet), though. Also, please note that serving XML as HTML is often considered harmful for the Internet. There's also a lot of concerns regarding Appendix C of the XHTML 1.0 Spec (dealing with HTML-Compatible XHTML markup). Hope this helps [2007-11-12 14:49:03] [EMAIL PROTECTED] IE6 isn't fully XHTML compliant and xml declaration is perfectly valid. Assigning to self as support for save options (including ability to suppress declaration) are currently in progress. Not yet fully integrated into DOM extension as this requires fairly recent libxml2 to work. [2007-11-12 13:22:27] dhopkins at mutinydesign dot co dot uk Description: This issue is similar to a similar one posted earlier ( http://bugs.php.net/bug.php?id=31130 ). Basically, I want to use the DOM functions to return valid XHTML - with trailing slashes - but the saveHTML method returns HTML 4.0 loose. As was pointed out in the above post, you can just use the saveXML method to return valid XHTML. However, there is a big problem with this. If you have a XHTML document that starts with the xml decleration ?xml?, Internet Explorer 6 doesn't read the HTML DTD. The result of which is a skewed document, various CSS attributes are not supported etc. You are basically trying to display a HTML document with an XML doctype. Currently, I am just trimming the xml decleration off the document, which I am sure you can appreciate is not a very good solution, but its the only option. Is it possible to add a feature that will return XML without the XML decleration? Or is this really something I need to take up with LibXML? There are quite a few people moaning about this issue, but so far no solutions has been provided. Reproduce code: --- $doc = new DomDocument(); $input = $doc-createElement('input'); $input-setAttribute('type', 'checkbox'); $input-setAttribute('checked', 'checked'); $doc-appendChild($input); echo $doc-saveXML(); Expected result: input type=checkbox checked=checked / Actual result: -- ?xml version=1.0 encoding=utf-8 standalone=yes? input type=checkbox checked / -- Edit this bug report at http://bugs.php.net/?id=43260edit=1
#43319 [Opn-Bgs]: Serialization of objects with Serializable interface and circular references
ID: 43319 Updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] -Status: Open +Status: Bogus Bug Type: Reproducible crash Operating System: Linux, Windows PHP Version: 5.2.5 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 When having your own serialization function you have to take care of recursion yourself. We can't handle infinite recursions in a good way, see other bug reports about recursion issues. Previous Comments: [2007-11-18 17:35:41] [EMAIL PROTECTED] I don't know if this is the more apropriated solution for this problem. When you try without the use of interface, you have the same recursion, but no crash. [2007-11-18 04:28:43] crrodriguez+php at suse dot de This causes infinite recursion,hence a crash.. I expect a very clear: zend_error(E_ERROR, Nesting level too deep - recursive dependency?); [2007-11-17 15:26:04] [EMAIL PROTECTED] Description: Apache crashes and CLI segfault when serializing objects which have circular references and implements the Serializable interface. Whitout the interface, the serialization and deserialization occurs without any problem. Reproduce code: --- ?php class A implements Serializable { private $b; public function setB($b) { $this-b = $b; } public function serialize() { return serialize($this-b); } public function unserialize($s) { $this-b = unserialize($s); } } class B { private $a; public function __construct($a) { $a-setB($this); $this-a = $a; } } $a = new A(); $b = new B($a); var_dump(serialize($b)); ? Expected result: The string of the serialized object. Actual result: -- Apache crash or cli segfault. -- Edit this bug report at http://bugs.php.net/?id=43319edit=1
#43295 [Opn]: php-cgi crash
ID: 43295 User updated by: pioklo at serveradmin dot pl Reported By: pioklo at serveradmin dot pl Status: Open Bug Type: CGI related Operating System: Debian 4.0 kernel 2.6.23.1 PHP Version: 5.2.5 New Comment: I have installed php 5.1.6 and the problem has passed away. Previous Comments: [2007-11-17 21:46:43] pioklo at serveradmin dot pl Bellow is clean backtrace: hardware is ok because I have tested this on 5 different servers.. ns79:~# gdb /usr/local/bin/php-cgi /home/admin/domains/poszkole.pl/public_html/beta/core GNU gdb 6.6.90.20070912-debian Copyright (C) 2007 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type show copying and show warranty for details. This GDB was configured as i486-linux-gnu... Using host libthread_db library /lib/libthread_db.so.1. warning: Can't read pathname for load map: Input/output error. Reading symbols from /lib/libcrypt.so.1...done. Loaded symbols for /lib/libcrypt.so.1 Reading symbols from /lib/librt.so.1...done. Loaded symbols for /lib/librt.so.1 Reading symbols from /usr/local/mysql/lib/mysql/libmysqlclient.so.15...done. Loaded symbols for /usr/local/mysql/lib/mysql/libmysqlclient.so.15 Reading symbols from /usr/lib/libz.so.1...done. Loaded symbols for /usr/lib/libz.so.1 Reading symbols from /usr/local/lib/libiconv.so.2...done. Loaded symbols for /usr/local/lib/libiconv.so.2 Reading symbols from /usr/local/lib/libfreetype.so.6...done. Loaded symbols for /usr/local/lib/libfreetype.so.6 Reading symbols from /usr/local/lib/libpng.so.3...done. Loaded symbols for /usr/local/lib/libpng.so.3 Reading symbols from /lib/libresolv.so.2...done. Loaded symbols for /lib/libresolv.so.2 Reading symbols from /lib/libm.so.6...done. Loaded symbols for /lib/libm.so.6 Reading symbols from /lib/libdl.so.2...done. Loaded symbols for /lib/libdl.so.2 Reading symbols from /lib/libnsl.so.1...done. Loaded symbols for /lib/libnsl.so.1 Reading symbols from /usr/lib/libxml2.so.2...done. Loaded symbols for /usr/lib/libxml2.so.2 Reading symbols from /lib/libc.so.6...done. Loaded symbols for /lib/libc.so.6 Reading symbols from /lib/libpthread.so.0...done. Loaded symbols for /lib/libpthread.so.0 Reading symbols from /lib/ld-linux.so.2...done. Loaded symbols for /lib/ld-linux.so.2 Reading symbols from /usr/lib/libnss_db.so.2...done. Loaded symbols for /usr/lib/libnss_db.so.2 Reading symbols from /lib/libnss_files.so.2...done. Loaded symbols for /lib/libnss_files.so.2 Reading symbols from /usr/lib/libdb-4.3.so...done. Loaded symbols for /usr/lib/libdb-4.3.so Reading symbols from /lib/libnss_dns.so.2...done. Loaded symbols for /lib/libnss_dns.so.2 Core was generated by `/usr/local/bin/php-cgi -b 80.86.81.87:1026'. Program terminated with signal 11, Segmentation fault. #0 0x08391412 in zend_mm_check_ptr (heap=0x86ee138, ptr=0x8820e54, silent=1, __zend_filename=0x868d9f7 /root/php-5.2.5/main/SAPI.c, __zend_lineno=445, __zend_orig_filename=0x0, __zend_orig_lineno=0) at /root/php-5.2.5/Zend/zend_alloc.c:1276 1276if (p-info._size != ZEND_MM_NEXT_BLOCK(p)-info._prev) { (gdb) bt full #0 0x08391412 in zend_mm_check_ptr (heap=0x86ee138, ptr=0x8820e54, silent=1, __zend_filename=0x868d9f7 /root/php-5.2.5/main/SAPI.c, __zend_lineno=445, __zend_orig_filename=0x0, __zend_orig_lineno=0) at /root/php-5.2.5/Zend/zend_alloc.c:1276 p = (zend_mm_block *) 0x8820e2c no_cache_notice = 0 had_problems = 0 valid_beginning = 1 #1 0x08392961 in _zend_mm_free_int (heap=0x86ee138, p=0x8820e54, __zend_filename=0x868d9f7 /root/php-5.2.5/main/SAPI.c, __zend_lineno=445, __zend_orig_filename=0x0, __zend_orig_lineno=0) at /root/php-5.2.5/Zend/zend_alloc.c:1909 mm_block = (zend_mm_block *) 0xcf0 next_block = (zend_mm_block *) 0x1 size = 3214980088 #2 0x0839396a in _efree (ptr=0x8820e54, __zend_filename=0x868d9f7 /root/php-5.2.5/main/SAPI.c, __zend_lineno=445, __zend_orig_filename=0x0, __zend_orig_lineno=0) at /root/php-5.2.5/Zend/zend_alloc.c:2277 No locals. #3 0x08366c4a in sapi_deactivate () at /root/php-5.2.5/main/SAPI.c:445 No locals. #4 0x0835f207 in php_request_shutdown (dummy=0x0) at /root/php-5.2.5/main/main.c:1494 __orig_bailout = (jmp_buf *) 0xbfa0c514 __bailout = {{__jmpbuf = {-1212280844, -1208259360, 0, -1079982904, 1434960001, 2145648110}, __mask_was_saved = 0, __saved_mask = {__val = {0, 3082575350, 0, 142330428, 0, 0, 1, 142330525, 0, 3082686452, 142634872, 3081258672, 3214984296, 3081774445, 3086707936, 0, 3214984360, 137964004, 142330468, 90, 57, 141237152, 1968, 0, 0, 0, 3082686452, 0, 3082690880, 3214984360, 142330428, 3082690880 report_memleaks = 1 '\001' #5 0x0842cb32
#43189 [Com]: Fails to link iconv
ID: 43189 Comment by: scott at mydogateit dot com Reported By: meh at mailinator dot com Status: Feedback Bug Type: ICONV related Operating System: Mac OS X 10.5 PHP Version: 5.3CVS-2007-11-04 (snap) New Comment: This is an issue with Leopards iconv.h file (/usr/include/iconv.h). Try this... $ sudo mv /usr/include/iconv.h /usr/include/iconv.h.leo_orig $ sudo ln -s /sw/include/iconv.h /usr/include/iconv.h and try make again. (I did this using iconv from MacPorts, but I assume the find dist will work just as well). Previous Comments: [2007-11-11 18:53:02] [EMAIL PROTECTED] How many iconv.h files do you have in your system? (search for *iconv*.h :) [2007-11-04 23:33:10] meh at mailinator dot com Description: ld: warning, duplicate dylib /sw/lib/libssl.0.9.7.dylib ld: warning, duplicate dylib /sw/lib/libcrypto.0.9.7.dylib Undefined symbols: _iconv_close, referenced from: _php_iconv_string in iconv.o _php_iconv_string in iconv.o __php_iconv_strlen in iconv.o __php_iconv_strpos in iconv.o __php_iconv_mime_decode in iconv.o __php_iconv_mime_decode in iconv.o __php_iconv_mime_decode in iconv.o _zif_iconv_substr in iconv.o _zif_iconv_substr in iconv.o _php_iconv_stream_filter_dtor in iconv.o _zif_iconv_mime_encode in iconv.o _zif_iconv_mime_encode in iconv.o _iconv_open, referenced from: _php_iconv_string in iconv.o __php_iconv_strlen in iconv.o __php_iconv_strpos in iconv.o __php_iconv_mime_decode in iconv.o __php_iconv_mime_decode in iconv.o _zif_iconv_substr in iconv.o _zif_iconv_substr in iconv.o _zif_iconv_mime_encode in iconv.o _zif_iconv_mime_encode in iconv.o _php_iconv_stream_filter_factory_create in iconv.o ld: symbol(s) not found collect2: ld returned 1 exit status make: *** [sapi/cli/php] Error 1 Reproduce code: --- ./configure --with-apxs2 --with-xsl --with-mysql=/sw --with-pdo --with-pdo-mysql=/sw --with-zlib --without-pear --with-iconv=/sw I've tried --with-iconv and --with-iconv=/usr as well. Configure succeedes with any of these, but linker fails every time. I have Fink installed: /sw/lib/libiconv.2.4.0.dylib /sw/lib/libiconv.2.dylib /sw/lib/libiconv.dylib /sw/lib/libiconv.la Expected result: Either configure should fail or linker should succeed. Actual result: -- Missing symbols... -- Edit this bug report at http://bugs.php.net/?id=43189edit=1
#43313 [Opn-Asn]: getopt doesn't handle unknown parameters.
ID: 43313 Updated by: [EMAIL PROTECTED] Reported By: RQuadling at GMail dot com -Status: Open +Status: Assigned Bug Type: CGI related Operating System: Windows XP SP2 PHP Version: 5.3CVS-2007-11-16 (snap) -Assigned To: +Assigned To: bjori Previous Comments: [2007-11-16 15:18:00] RQuadling at GMail dot com Description: getopt() stops processing at the first unknown parameter. I'm not sure if this is ... a php bug - getopt should return them as is or ... a doc bug - getopt() will cease operation at the first hurdle. My preference is to return them as is. Maybe a third param to the function to collect unknown parameters. This would provide backward compatibility if the function didn't die when an unknown parameter was reached. The code is a simple test to examine the command line. Run this with this parameter -a 1 and then with these broken -a 1 Reproduce code: --- ?php var_dump($_SERVER['argv'], getopt('a:b', array('apple=', 'bag'))); ? Expected result: array(3) { [0]= string(17) C:\phpargtest.php [1]= string(2) -a [2]= string(1) 1 } array(1) { [a]= string(1) 1 } array(4) { [0]= string(17) C:\phpargtest.php [1]= string(6) broken [2]= string(2) -a [3]= string(1) 1 } array(1) { [0]= string(6) broken [a]= string(1) 1 } Actual result: -- array(3) { [0]= string(17) C:\phpargtest.php [1]= string(2) -a [2]= string(1) 1 } array(1) { [a]= string(1) 1 } array(4) { [0]= string(17) C:\phpargtest.php [1]= string(6) broken [2]= string(2) -a [3]= string(1) 1 } array(0) { } -- Edit this bug report at http://bugs.php.net/?id=43313edit=1
#43325 [NEW]: feof() hangs on UDP stream
From: mertcan at dpozitif dot com Operating system: Centos 5.0 PHP version: 5.2.5 PHP Bug Type: Streams related Bug description: feof() hangs on UDP stream Description: Using feof on UDP hangs. It should give true or false, in my example it should give true but it hangs. I've tried many ways but it always hangs. Reproduce code: --- $msg = challenge rcon; $fp = fsockopen(udp://62.68.207.16,27015, $errno, $errstr); fputs($fp, $msg, strlen($msg)); $response = fgets($fp, 1024); $challenge = substr($response, 19, strlen($response) - 20); $msg = rcon .$challenge. \123456\ .$komut.chr(0); fputs($fp, $msg, strlen($msg)); echo feof($fp) ? 'true':'false'; $response .= fgets($fp, 32); fclose ($fp); Expected result: true Actual result: -- hangs -- Edit bug report at http://bugs.php.net/?id=43325edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43325r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43325r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43325r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43325r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43325r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43325r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43325r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43325r=needscript Try newer version:http://bugs.php.net/fix.php?id=43325r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43325r=support Expected behavior:http://bugs.php.net/fix.php?id=43325r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43325r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43325r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43325r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43325r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43325r=dst IIS Stability:http://bugs.php.net/fix.php?id=43325r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43325r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43325r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43325r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43325r=mysqlcfg
#43305 [Fbk-Opn]: SQLite.dll not loading
ID: 43305 User updated by: ivaplace at yahoo dot co dot uk Reported By: ivaplace at yahoo dot co dot uk -Status: Feedback +Status: Open Bug Type: Dynamic loading Operating System: Windows 2003 PHP Version: 5.2.5 New Comment: The extra dlls were: php_sqlite.dll and php_pdo_sqlite.dll I uncommented: extension=php_sqlite.dll extension=php_pd_sqlite.dll Previous Comments: [2007-11-16 11:39:55] [EMAIL PROTECTED] Extra dlls are the ones that need to be installed as those are required by PHP core and several extensions. They're found in the zip package you installed PHP from (or if you used the installer, that should do it for you..). But what exactly did you put in php.ini to load the sqlite extension? [2007-11-16 09:31:19] ivaplace at yahoo dot co dot uk Could you please tell me which are the 'extra dlls'? The other dlls I uncommented in php.ini all loaded fine. [2007-11-15 22:48:32] [EMAIL PROTECTED] And exactly what did you put in php.ini? [2007-11-15 22:47:38] [EMAIL PROTECTED] Did you install the extra dlls too? (and if you upgraded, you upgraded those as well?) [2007-11-15 16:28:22] ivaplace at yahoo dot co dot uk Description: pdo_sqlite.dll and sqlite.dll not loading although uncommented in php.ini. Error message suggests files not found in the ext directory where they clearly exist -- Edit this bug report at http://bugs.php.net/?id=43305edit=1
#43305 [Opn]: SQLite.dll not loading
ID: 43305 User updated by: ivaplace at yahoo dot co dot uk Reported By: ivaplace at yahoo dot co dot uk Status: Open Bug Type: Dynamic loading Operating System: Windows 2003 PHP Version: 5.2.5 New Comment: Those were the only changes I made - I could find no other references. Previous Comments: [2007-11-18 23:28:12] ivaplace at yahoo dot co dot uk The extra dlls were: php_sqlite.dll and php_pdo_sqlite.dll I uncommented: extension=php_sqlite.dll extension=php_pd_sqlite.dll [2007-11-16 11:39:55] [EMAIL PROTECTED] Extra dlls are the ones that need to be installed as those are required by PHP core and several extensions. They're found in the zip package you installed PHP from (or if you used the installer, that should do it for you..). But what exactly did you put in php.ini to load the sqlite extension? [2007-11-16 09:31:19] ivaplace at yahoo dot co dot uk Could you please tell me which are the 'extra dlls'? The other dlls I uncommented in php.ini all loaded fine. [2007-11-15 22:48:32] [EMAIL PROTECTED] And exactly what did you put in php.ini? [2007-11-15 22:47:38] [EMAIL PROTECTED] Did you install the extra dlls too? (and if you upgraded, you upgraded those as well?) 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/43305 -- Edit this bug report at http://bugs.php.net/?id=43305edit=1
#43318 [Opn-Asn]: const allowed outside class definition
ID: 43318 Updated by: [EMAIL PROTECTED] -Summary: Const accepts array Reported By: felipensp at gmail dot com -Status: Open +Status: Assigned Bug Type:Scripting Engine problem PHP Version: 5.3CVS-2007-11-17 (snap) -Assigned To: +Assigned To: dmitry New Comment: Dmitry, I think this is caused by the namespace patches. Previous Comments: [2007-11-18 03:35:57] crrodriguez+php at suse dot de in 5_3 there seems to be an issue ( maybe a change) that allows const outside classes, const outside class seems to be wrong though. in 5_2 it causes a syntax error, unexpected T_CONST in.. [2007-11-17 13:19:58] felipensp at gmail dot com Description: Const now accepts array? Reproduce code: --- ?php const foo = array(1, 2, 3); var_dump(foo); var_dump(constant('foo')); Expected result: Error ? Actual result: -- array(3) { [0]= int(1) [1]= int(2) [2]= int(3) } array(3) { [0]= int(1) [1]= int(2) [2]= int(3) } -- Edit this bug report at http://bugs.php.net/?id=43318edit=1
#43305 [Opn-Fbk]: SQLite.dll not loading
ID: 43305 Updated by: [EMAIL PROTECTED] Reported By: ivaplace at yahoo dot co dot uk -Status: Open +Status: Feedback Bug Type: Dynamic loading Operating System: Windows 2003 PHP Version: 5.2.5 New Comment: I guess you made a typo when you copied this: extension=php_pd_sqlite.dll (the missing 'o' there) But did you install the extra dlls or not? Is PDO itself loaded? Previous Comments: [2007-11-18 23:30:00] ivaplace at yahoo dot co dot uk Those were the only changes I made - I could find no other references. [2007-11-18 23:28:12] ivaplace at yahoo dot co dot uk The extra dlls were: php_sqlite.dll and php_pdo_sqlite.dll I uncommented: extension=php_sqlite.dll extension=php_pd_sqlite.dll [2007-11-16 11:39:55] [EMAIL PROTECTED] Extra dlls are the ones that need to be installed as those are required by PHP core and several extensions. They're found in the zip package you installed PHP from (or if you used the installer, that should do it for you..). But what exactly did you put in php.ini to load the sqlite extension? [2007-11-16 09:31:19] ivaplace at yahoo dot co dot uk Could you please tell me which are the 'extra dlls'? The other dlls I uncommented in php.ini all loaded fine. [2007-11-15 22:48:32] [EMAIL PROTECTED] And exactly what did you put in php.ini? 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/43305 -- Edit this bug report at http://bugs.php.net/?id=43305edit=1
#43322 [Com]: $this[] not produces error
ID: 43322 Comment by: crrodriguez at suse dot de Reported By: felipensp at gmail dot com Status: Open Bug Type:Scripting Engine problem PHP Version: 6CVS-2007-11-18 (snap) New Comment: ?php $this[] = new stdClass; // no error ? happends as well on 5_3 as is wrong :( maybe dmitry can check this out. Previous Comments: [2007-11-18 13:15:38] felipensp at gmail dot com Description: $this[] outside of class not produces error. Reproduce code: --- ?php class foo { public function __construct() { $this[] = 1; } } // Fatal error: Cannot re-assign $this // $this = new foo; // Fatal error: Using $this when not in object context // $this-a = new foo; // Fatal error: Cannot use object of type foo as array // new foo; $this[] = new stdClass; // no error Expected result: Fatal error: Using $this when not in object context Actual result: -- No error -- Edit this bug report at http://bugs.php.net/?id=43322edit=1
#43295 [Opn-Fbk]: php-cgi crash
ID: 43295 Updated by: [EMAIL PROTECTED] Reported By: pioklo at serveradmin dot pl -Status: Open +Status: Feedback Bug Type: CGI related Operating System: Debian 4.0 kernel 2.6.23.1 PHP Version: 5.2.5 New Comment: Please don't post any backtraces anymore. What exactly does this gry.php do? Try shorten the script to bare minimum which still causes the problem. Previous Comments: [2007-11-18 21:42:53] pioklo at serveradmin dot pl I have installed php 5.1.6 and the problem has passed away. [2007-11-17 21:46:43] pioklo at serveradmin dot pl Bellow is clean backtrace: hardware is ok because I have tested this on 5 different servers.. ns79:~# gdb /usr/local/bin/php-cgi /home/admin/domains/poszkole.pl/public_html/beta/core GNU gdb 6.6.90.20070912-debian Copyright (C) 2007 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type show copying and show warranty for details. This GDB was configured as i486-linux-gnu... Using host libthread_db library /lib/libthread_db.so.1. warning: Can't read pathname for load map: Input/output error. Reading symbols from /lib/libcrypt.so.1...done. Loaded symbols for /lib/libcrypt.so.1 Reading symbols from /lib/librt.so.1...done. Loaded symbols for /lib/librt.so.1 Reading symbols from /usr/local/mysql/lib/mysql/libmysqlclient.so.15...done. Loaded symbols for /usr/local/mysql/lib/mysql/libmysqlclient.so.15 Reading symbols from /usr/lib/libz.so.1...done. Loaded symbols for /usr/lib/libz.so.1 Reading symbols from /usr/local/lib/libiconv.so.2...done. Loaded symbols for /usr/local/lib/libiconv.so.2 Reading symbols from /usr/local/lib/libfreetype.so.6...done. Loaded symbols for /usr/local/lib/libfreetype.so.6 Reading symbols from /usr/local/lib/libpng.so.3...done. Loaded symbols for /usr/local/lib/libpng.so.3 Reading symbols from /lib/libresolv.so.2...done. Loaded symbols for /lib/libresolv.so.2 Reading symbols from /lib/libm.so.6...done. Loaded symbols for /lib/libm.so.6 Reading symbols from /lib/libdl.so.2...done. Loaded symbols for /lib/libdl.so.2 Reading symbols from /lib/libnsl.so.1...done. Loaded symbols for /lib/libnsl.so.1 Reading symbols from /usr/lib/libxml2.so.2...done. Loaded symbols for /usr/lib/libxml2.so.2 Reading symbols from /lib/libc.so.6...done. Loaded symbols for /lib/libc.so.6 Reading symbols from /lib/libpthread.so.0...done. Loaded symbols for /lib/libpthread.so.0 Reading symbols from /lib/ld-linux.so.2...done. Loaded symbols for /lib/ld-linux.so.2 Reading symbols from /usr/lib/libnss_db.so.2...done. Loaded symbols for /usr/lib/libnss_db.so.2 Reading symbols from /lib/libnss_files.so.2...done. Loaded symbols for /lib/libnss_files.so.2 Reading symbols from /usr/lib/libdb-4.3.so...done. Loaded symbols for /usr/lib/libdb-4.3.so Reading symbols from /lib/libnss_dns.so.2...done. Loaded symbols for /lib/libnss_dns.so.2 Core was generated by `/usr/local/bin/php-cgi -b 80.86.81.87:1026'. Program terminated with signal 11, Segmentation fault. #0 0x08391412 in zend_mm_check_ptr (heap=0x86ee138, ptr=0x8820e54, silent=1, __zend_filename=0x868d9f7 /root/php-5.2.5/main/SAPI.c, __zend_lineno=445, __zend_orig_filename=0x0, __zend_orig_lineno=0) at /root/php-5.2.5/Zend/zend_alloc.c:1276 1276if (p-info._size != ZEND_MM_NEXT_BLOCK(p)-info._prev) { (gdb) bt full #0 0x08391412 in zend_mm_check_ptr (heap=0x86ee138, ptr=0x8820e54, silent=1, __zend_filename=0x868d9f7 /root/php-5.2.5/main/SAPI.c, __zend_lineno=445, __zend_orig_filename=0x0, __zend_orig_lineno=0) at /root/php-5.2.5/Zend/zend_alloc.c:1276 p = (zend_mm_block *) 0x8820e2c no_cache_notice = 0 had_problems = 0 valid_beginning = 1 #1 0x08392961 in _zend_mm_free_int (heap=0x86ee138, p=0x8820e54, __zend_filename=0x868d9f7 /root/php-5.2.5/main/SAPI.c, __zend_lineno=445, __zend_orig_filename=0x0, __zend_orig_lineno=0) at /root/php-5.2.5/Zend/zend_alloc.c:1909 mm_block = (zend_mm_block *) 0xcf0 next_block = (zend_mm_block *) 0x1 size = 3214980088 #2 0x0839396a in _efree (ptr=0x8820e54, __zend_filename=0x868d9f7 /root/php-5.2.5/main/SAPI.c, __zend_lineno=445, __zend_orig_filename=0x0, __zend_orig_lineno=0) at /root/php-5.2.5/Zend/zend_alloc.c:2277 No locals. #3 0x08366c4a in sapi_deactivate () at /root/php-5.2.5/main/SAPI.c:445 No locals. #4 0x0835f207 in php_request_shutdown (dummy=0x0) at /root/php-5.2.5/main/main.c:1494 __orig_bailout = (jmp_buf *) 0xbfa0c514 __bailout = {{__jmpbuf = {-1212280844, -1208259360, 0, -1079982904, 1434960001, 2145648110}, __mask_was_saved = 0, __saved_mask = {__val = {0, 3082575350, 0, 142330428, 0,
#43326 [NEW]: compilation of mysqli breaks due to bad #ifdef
From: gk at gknw dot de Operating system: NetWare PHP version: 5.2.5 PHP Bug Type: Compile Failure Bug description: compilation of mysqli breaks due to bad #ifdef Description: Compilation of mysqli extension for NetWare platform breaks with PHP 5.2.5 due to bad #ifdef expression; seems that not all compilers like an #ifdef combined with an #if; here's a patch which solves the issue: --- mysqli.c.orig Mon Oct 22 12:35:34 2007 +++ mysqli.cMon Nov 19 00:24:16 2007 @@ -693,7 +693,7 @@ */ PHP_RINIT_FUNCTION(mysqli) { -#ifdef ZTS MYSQL_VERSION_ID = 4 +#if defined(ZTS) MYSQL_VERSION_ID = 4 if (mysql_thread_init()) { return FAILURE; } @@ -709,7 +709,7 @@ */ PHP_RSHUTDOWN_FUNCTION(mysqli) { -#ifdef ZTS MYSQL_VERSION_ID = 4 +#if defined(ZTS) MYSQL_VERSION_ID = 4 mysql_thread_end(); #endif if (MyG(error_msg)) { Reproduce code: --- compilation breaks using Metrowerks CodeWarrior compiler for NetWare. Expected result: compilation succeeds. Actual result: -- compilation breaks. -- Edit bug report at http://bugs.php.net/?id=43326edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43326r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43326r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43326r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43326r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43326r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43326r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43326r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43326r=needscript Try newer version:http://bugs.php.net/fix.php?id=43326r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43326r=support Expected behavior:http://bugs.php.net/fix.php?id=43326r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43326r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43326r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43326r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43326r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43326r=dst IIS Stability:http://bugs.php.net/fix.php?id=43326r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43326r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43326r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43326r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43326r=mysqlcfg
#43326 [Opn-Csd]: compilation of mysqli breaks due to bad #ifdef
ID: 43326 Updated by: [EMAIL PROTECTED] Reported By: gk at gknw dot de -Status: Open +Status: Closed Bug Type: Compile Failure Operating System: NetWare PHP Version: 5.2.5 New Comment: Already fixed in CVS. Previous Comments: [2007-11-18 23:42:35] gk at gknw dot de Description: Compilation of mysqli extension for NetWare platform breaks with PHP 5.2.5 due to bad #ifdef expression; seems that not all compilers like an #ifdef combined with an #if; here's a patch which solves the issue: --- mysqli.c.orig Mon Oct 22 12:35:34 2007 +++ mysqli.cMon Nov 19 00:24:16 2007 @@ -693,7 +693,7 @@ */ PHP_RINIT_FUNCTION(mysqli) { -#ifdef ZTS MYSQL_VERSION_ID = 4 +#if defined(ZTS) MYSQL_VERSION_ID = 4 if (mysql_thread_init()) { return FAILURE; } @@ -709,7 +709,7 @@ */ PHP_RSHUTDOWN_FUNCTION(mysqli) { -#ifdef ZTS MYSQL_VERSION_ID = 4 +#if defined(ZTS) MYSQL_VERSION_ID = 4 mysql_thread_end(); #endif if (MyG(error_msg)) { Reproduce code: --- compilation breaks using Metrowerks CodeWarrior compiler for NetWare. Expected result: compilation succeeds. Actual result: -- compilation breaks. -- Edit this bug report at http://bugs.php.net/?id=43326edit=1
#42291 [Opn-Fbk]: Uploaded file permissions vary depending on file system configuration
ID: 42291 Updated by: [EMAIL PROTECTED] Reported By: rob-phpbugs at tigertech dot com -Status: Open +Status: Feedback Bug Type: Filesystem function related Operating System: Linux PHP Version: 5.2.4 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: [2007-11-05 23:28:25] rob-phpbugs at tigertech dot com I fear this bug could be ignored because I tagged it as happening on PHP 4. Just to make sure it's clear, I'm retagging it as happening in PHP 5.2.4 -- it affects all versions. [2007-11-04 17:16:19] marcel dot wiechmann at gmail dot com Same problem here. But not only under php 4.4.7 also under php 5.2.4 [2007-11-04 15:51:26] chh at innov8 dot ch I can confirm this behaviour. If upload_tmp_dir is on the same filesystem as the destination folder (normally the webspace of the customer(s) then the file permissions are set to 0600 - otherwise 0644 (umask at 0022), when using move_uploaded_file(). The temp file - before calling move_uploaded_file() - also has 0600 permissions. This leads to a problem when using suphp (suexec, fastcgi or whatever) and upload-functions in php applications which do not set the permissions after using move_uploaded_file() [Joomla seems to be such a candidate - Typo3 does it right..]. If you upload a static file which should be readable by the webserver but isn't because only PHP (and other user running applications) can access the file. All Upload functions should use a chmod() after move_uploded_file()... [2007-08-14 03:50:47] rob-phpbugs at tigertech dot com Description: On all current PHP versions, move_uploaded_file() creates a destination file that is either mode 0600 or 0644 (on Linux, anyway), depending on whether move_uploaded_file() needed to copy the file across filesystems. If the file can be moved (renamed), then the resulting file is mode 0600, because the file was originally created with mkstemp. If the file needs to be copied, the resulting mode is 0644 instead (assuming a normal umask of 022). This behavior appears (to the script author who isn't familiar with how move_uploaded_file works internally) inconsistent and surprising, and is undocumented. Expected result: Permissions given to uploaded files should be consistent, depending only on the umask setting. In other words, if I pass move_uploaded_file() the same parameters with the same umask value, I would expect to see the same resulting permissions, regardless of whether PHP's temporary file location happens to be on the same file system as the final destination. One could argue that a script author should be aware of this behavior, and should therefore find out whether the temporary location is on the same file system and plan for the resulting behavior. However, that doesn't seem practical. First of all, the current behavior isn't documented, so few people are aware of it. Secondly, the file system that is used for temporary files may be out of the script author's control, and may change without his or her knowledge (especially in a shared hosting environment, etc.) This could have security implications: Uploaded files that used to be given mode 0600 and were therefore considered secure because the script author thought that's just how PHP works will suddenly start getting mode 0644 if the server admin moves /tmp to a dedicated partition, for example. Making the behavior consistent (one way or the other) would avoid confusion. If the behavior can't be made consistent, it would be good to document the current behavior so that authors know that relying on the mode is not safe. Actual result: -- Permissions are set to either 0600 or 0644 depending on filesystem configuration. -- Edit this bug report at http://bugs.php.net/?id=42291edit=1
#40198 [Opn-Fbk]: Column name is not double quoted
ID: 40198 Updated by: [EMAIL PROTECTED] Reported By: chores at jp1 dot cx -Status: Open +Status: Feedback Bug Type: PostgreSQL related Operating System: FreeBSD 6.2 PHP Version: 5.2.4 Assigned To: yohgaki 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 Really, try the snapshot.. Previous Comments: [2007-11-17 06:02:21] chores at jp1 dot cx non-fix v5.2.4 [2007-07-19 01:00:03] php-bugs at lists dot php dot net No feedback was provided for this bug for over a week, so it is being suspended automatically. If you are able to provide the information that was originally requested, please do so and change the status of the bug back to Open. [2007-07-11 12:54:37] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows (zip): http://snaps.php.net/win32/php5.2-win32-latest.zip For Windows (installer): http://snaps.php.net/win32/php5.2-win32-installer-latest.msi [2007-01-23 00:26:25] chores at jp1 dot cx Expected result (Correction): - INSERT INTO t_test (c1,C2) VALUES ('0','0'); [2007-01-22 18:53:33] chores at jp1 dot cx Description: Column name is not double quoted % psql -U testuser testdb testdb=# CREATE TABLE t_test (c1 char(10), C2 char(10)); testdb=# \q % ./test.php INSERT INTO t_test (c1,C2) VALUES ('0','0'); % psql -U testuser testdb testdb=# INSERT INTO t_test (c1,C2) VALUES ('0','0'); ERROR: column c2 of relation t_test does not exist Reproduce code: --- (test.php) #!/usr/local/bin/php ?php $db = pg_connect('dbname=testdb user=testuser'); $vals['c1'] = '0'; $vals['C2'] = '0'; echo pg_insert($db, 't_test', $vals, PGSQL_DML_STRING); ? Expected result: INSERT INTO t_test (c1,C2) VALUES ('0','0'); Actual result: -- INSERT INTO t_test (c1,C2) VALUES ('0','0'); -- Edit this bug report at http://bugs.php.net/?id=40198edit=1
#43256 [Fbk-Opn]: wrong behaviour with header()
ID: 43256 User updated by: carsten_sttgt at gmx dot de Reported By: carsten_sttgt at gmx dot de -Status: Feedback +Status: Open Bug Type: IIS related Operating System: Windows_NT PHP Version: 5.2.5 New Comment: There's also this setting: ; cgi.nph = 1 There is no difference: | D:\PHPcat nph-test.php | ?php | header('Location: http://www.example.com/', true, 303); | ? | | D:\PHPpear-request -r 0 -S -o http://localhost/phpinfo.php |\ | grep -E cgi.rfc2616_headers|cgi.nph | cgi.nph11 | cgi.rfc2616_headers11 | | D:\PHPpear-request -r 0 -S http://localhost/nph-test.php | GET http://localhost/nph-test.php -- ERROR: Malformed response BTW: This setting is only available with CGI, but not with ISAPI. Regards, Carsten Previous Comments: [2007-11-17 22:20:49] [EMAIL PROTECTED] There's also this setting: ; cgi.nph = 1 Try to turn that off / on. [2007-11-17 12:03:15] carsten_sttgt at gmx dot de what is this set in your php.ini: cgi.rfc2616_headers = 0 Now you address the NPH-CGI issue. Correct, my first tests was with 0. Now with 1: | D:\PHPpear-request -r 0 -S -o http://localhost/phpinfo.php |\ | grep cgi.rfc2616_headers | cgi.rfc2616_headers11 with Testscript 1: -- | D:\PHPpear-request -r 0 -S http://localhost/nph-test.php | GET http://localhost/nph-test.php -- 303 See Other Works now. (thanks for the hint) with Testscript 2: -- | D:\PHPpear-request -r 0 -S http://localhost/nph-test.php | GET http://localhost/nph-test.php -- ERROR: Malformed response Don't work. So we have a similar result as with ISAPI. There is only a correct result, if you also explicitly set the Status header. Only setting the Location header with the code parameter does not work correctly. Regards, Carsten [2007-11-16 12:46:58] [EMAIL PROTECTED] what is this set in your php.ini: cgi.rfc2616_headers = 0 (look in the phpinfo() output!) [2007-11-12 17:59:53] carsten_sttgt at gmx dot de What are you using exactly with IIS? PHP FastCGI binary or ISAPI module? As you can see in the examples: both. Or in other words: I can't know, if a script is used with ISAPI or CGI on a customer installation. note: Only former is really useful/working properly) But this is only true for PHP. Why? With other scripting languages, I have no problem to set this header via ISAPI. And with PHP/ISAPI there is only one problem: I must use first a header() call to set the status, and then I can use header() with location. | header('HTTP/1.0 303 See Other'); | header('Location: http://www.example.com/'); (The first header() call is normaly only necessary, if I want change the default reason phrase) But what ever happens in the PHP core during the first header call, should also done from PHP, if I use the status parameter in header() (like it works with Apache): | header('Location: http://www.example.com/', true, 303); Regarding PHP/CGI: A CGI which want set/use it't own headers (not parsed from the server), must have a script name which starts with nph- (that's not only true for IIS, also for other webservers). But if the name from a PHP script is e.g. nph-test.php, there is no correct output at all. (as before, with other scripting languages, this works without problems.) (Or all together: With other scripting languages I use the same documented command(s) to set the header on all webservers in the same way. Only with CGI I must rename the script. With PHP the same command does work different on different webserver and nph-CGI does't work at all.) Regards, Carsten [2007-11-12 11:23:51] [EMAIL PROTECTED] What are you using exactly with IIS? PHP FastCGI binary or ISAPI module? (note: Only former is really useful/working properly) 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/43256 -- Edit this bug report at http://bugs.php.net/?id=43256edit=1
#43327 [NEW]: wrong return value from mail(), if sendmail_path is wrong
From: carsten_sttgt at gmx dot de Operating system: Windows_NT PHP version: 5.2.5 PHP Bug Type: Mail related Bug description: wrong return value from mail(), if sendmail_path is wrong Description: Hello, on Windows, mail() allways returns true, regardless if sendmail_path is wrong, or sendmail returns an error code. Regards, Carsten Reproduce code: --- ?php error_reporting(E_ALL); $return = mail('[EMAIL PROTECTED]', 'Test', 'Test'); var_dump($return); ? Expected result: Like on *nix: | % ./php -d sendmail_path=/foo/bar test.php | /foo/bar: not found | bool(false) | % Actual result: -- On Windows: | D:\PHPphp -d sendmail_path=/foo/bar test.php | bool(true) | | D:\PHP -- Edit bug report at http://bugs.php.net/?id=43327edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43327r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43327r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43327r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43327r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43327r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43327r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43327r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43327r=needscript Try newer version:http://bugs.php.net/fix.php?id=43327r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43327r=support Expected behavior:http://bugs.php.net/fix.php?id=43327r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43327r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43327r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43327r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43327r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43327r=dst IIS Stability:http://bugs.php.net/fix.php?id=43327r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43327r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43327r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43327r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43327r=mysqlcfg
#43328 [NEW]: About the bugs #42590, #43316
From: dagdamor at simps dot ru Operating system: PHP version: 5.2.5 PHP Bug Type: Strings related Bug description: About the bugs #42590, #43316 Description: To Ilia, http://bugs.php.net/bug.php?id=43316 Are you sure? Check carefully the http://www.php.net/manual/en/language.types.string.php, table 11.1, and what's written right after it. One should think a little bit before making fundamental changes in the parser and breaking BC *that* much... :| -- Edit bug report at http://bugs.php.net/?id=43328edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43328r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43328r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43328r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43328r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43328r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43328r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43328r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43328r=needscript Try newer version:http://bugs.php.net/fix.php?id=43328r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43328r=support Expected behavior:http://bugs.php.net/fix.php?id=43328r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43328r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43328r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43328r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43328r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43328r=dst IIS Stability:http://bugs.php.net/fix.php?id=43328r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43328r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43328r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43328r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43328r=mysqlcfg
#43329 [NEW]: snmp2_walk returns wrong value
From: ras at e-gerbil dot net Operating system: FreeBSD 7.0-BETA3 PHP version: 5.2.5 PHP Bug Type: SNMP related Bug description: snmp2_walk returns wrong value Description: snmp2_walk() is occasionally (but consistently) returning the wrong value for certain OIDs on certain devices. snmp2_real_walk(), snmp2_get, and other external utilities all report the correct value. Reproduce code: --- $test1 = snmp2_get($dev, $comm, ifHCInOctets.163); $test2 = snmp2_real_walk($dev, $comm, ifHCInOctets); $test3 = snmp2_walk($dev, $comm, ifHCInOctets); $proof = snmp2_walk($dev, $comm, ifIndex); print SNMP2_GET test: $test1\n; print SNMP2_REAL_WALK test: {$test2['.1.3.6.1.2.1.31.1.1.1.6.163']}\n; print SNMP2_WALK test: {$test3[83]}\n; print Proof that I'm looking at the right ifindex: {$proof[83]}\n; Expected result: I expect snmp2_walk() to return correct results. :) Actual result: -- SNMP2_GET test: 1280817516439889 SNMP2_REAL_WALK test: 1280817516439889 SNMP2_WALK test: 3545696399506456 Proof that I'm looking at the right ifindex: 163 -- Edit bug report at http://bugs.php.net/?id=43329edit=1 -- Try a CVS snapshot (PHP 4.4): http://bugs.php.net/fix.php?id=43329r=trysnapshot44 Try a CVS snapshot (PHP 5.2): http://bugs.php.net/fix.php?id=43329r=trysnapshot52 Try a CVS snapshot (PHP 5.3): http://bugs.php.net/fix.php?id=43329r=trysnapshot53 Try a CVS snapshot (PHP 6.0): http://bugs.php.net/fix.php?id=43329r=trysnapshot60 Fixed in CVS: http://bugs.php.net/fix.php?id=43329r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=43329r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=43329r=needtrace Need Reproduce Script:http://bugs.php.net/fix.php?id=43329r=needscript Try newer version:http://bugs.php.net/fix.php?id=43329r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=43329r=support Expected behavior:http://bugs.php.net/fix.php?id=43329r=notwrong Not enough info: http://bugs.php.net/fix.php?id=43329r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=43329r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=43329r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=43329r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=43329r=dst IIS Stability:http://bugs.php.net/fix.php?id=43329r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=43329r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=43329r=float No Zend Extensions: http://bugs.php.net/fix.php?id=43329r=nozend MySQL Configuration Error:http://bugs.php.net/fix.php?id=43329r=mysqlcfg
#43329 [Opn-Bgs]: snmp2_walk returns wrong value
ID: 43329 User updated by: ras at e-gerbil dot net Reported By: ras at e-gerbil dot net -Status: Open +Status: Bogus Bug Type: SNMP related Operating System: FreeBSD 7.0-BETA3 PHP Version: 5.2.5 New Comment: Nevermind I'm a tard, it is misaligning, array_values() squishes things because an interface elsewhere on the router wasn't return a value for counters but was for ifdescr... the choice of indexes here really sucks, can't you just give me back an array with a numeric ifindex instead of the whole darn oid. :) Previous Comments: [2007-11-19 05:09:11] ras at e-gerbil dot net Description: snmp2_walk() is occasionally (but consistently) returning the wrong value for certain OIDs on certain devices. snmp2_real_walk(), snmp2_get, and other external utilities all report the correct value. Reproduce code: --- $test1 = snmp2_get($dev, $comm, ifHCInOctets.163); $test2 = snmp2_real_walk($dev, $comm, ifHCInOctets); $test3 = snmp2_walk($dev, $comm, ifHCInOctets); $proof = snmp2_walk($dev, $comm, ifIndex); print SNMP2_GET test: $test1\n; print SNMP2_REAL_WALK test: {$test2['.1.3.6.1.2.1.31.1.1.1.6.163']}\n; print SNMP2_WALK test: {$test3[83]}\n; print Proof that I'm looking at the right ifindex: {$proof[83]}\n; Expected result: I expect snmp2_walk() to return correct results. :) Actual result: -- SNMP2_GET test: 1280817516439889 SNMP2_REAL_WALK test: 1280817516439889 SNMP2_WALK test: 3545696399506456 Proof that I'm looking at the right ifindex: 163 -- Edit this bug report at http://bugs.php.net/?id=43329edit=1