[PHP-BUG] Bug #65458 [NEW]: curl memory leak
From: peter57 at post dot sk Operating system: Linux/Windows PHP version: 5.4.18 Package: cURL related Bug Type: Bug Bug description:curl memory leak Description: When CURLOPT_HTTPHEADER is called more than once on the same curl handle, php/curl does not free the memory of the previous header data. Similar to bug 63859. Test script: --- https://bugs.php.net/bug.php?id=65458&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=65458&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=65458&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=65458&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=65458&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=65458&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=65458&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=65458&r=needscript Try newer version: https://bugs.php.net/fix.php?id=65458&r=oldversion Not developer issue:https://bugs.php.net/fix.php?id=65458&r=support Expected behavior: https://bugs.php.net/fix.php?id=65458&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=65458&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=65458&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=65458&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=65458&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=65458&r=dst IIS Stability: https://bugs.php.net/fix.php?id=65458&r=isapi Install GNU Sed:https://bugs.php.net/fix.php?id=65458&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=65458&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=65458&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=65458&r=mysqlcfg
Bug #62639 [Com]: XML structure broken
Edit report at https://bugs.php.net/bug.php?id=62639&edit=1 ID: 62639 Comment by: sergey at shymko dot net Reported by:alexshock at yandex dot ru Summary:XML structure broken Status: Assigned Type: Bug Package:SimpleXML related Operating System: debian 6.0.5 PHP Version:5.4.5 Assigned To:acurioso Block user comment: N Private report: N New Comment: The following workaround seems to fix both dumping and type casting: _fixNode($node); } return $result; } protected function _fixNode(SimpleXMLElement $node) { if (!$node && (string)$node) { $dom = dom_import_simplexml($node); $dom->parentNode->replaceChild(clone $dom, $dom); } } } Unfortunately, the same approach does not work for children() method, because of mysterious nature of its returned value. Despite returned object manifests itself as an instance of SimpleXMLElement, it does not behave as such. For instance, it is incompatible with dom_import_simplexml(). So, what kind of SimpleXMLElement is that? Previous Comments: [2013-06-14 00:21:27] info at fuktommy dot com It causes not only wrong var_dump and print_r, but also wrong boolean cast. Test script: $xml = << Some String XML; $b = simplexml_load_string($xml)->xpath('/a/b'); var_dump((string)$b[0]); var_dump((bool)$b[0]); Expected result: string(11) "Some String" bool(true) Actual result: -- string(11) "Some String" bool(false) [2013-04-24 07:48:36] larue...@php.net I think we should revert the previous fix at now, since this new bug is more critical than the previous one. and I think the key problem there is that we can not tell iterating from convert_to_array in the sxe_get_prop_hash without that, I don't think we can get a good fix for the 034.phpt [2013-02-18 21:21:48] sala...@php.net Related To: Bug #62203 [2012-07-30 01:57:05] willfi...@php.net I think that would make more sense. Thanks, Andrew. [2012-07-30 00:58:13] acuri...@php.net I can confirm that reverting that patch does fix the bug; however, it causes the original test to fail again: = FAILED TEST SUMMARY - SimpleXML: cast to array [ext/simplexml/tests/034.phpt] Bug #51615 (PHP crash with wrong HTML in SimpleXML) [ext/simplexml/tests/bug51615.phpt] = See: ext/simplexml/tests/034.phpt for more information. Ignore bug51615.phpt for now. That is just a side effect of test 34. I would actually prefer if I could take the first stab at this bug myself since it was clearly introduced in my code. I'd be hesitate to just revert the changes since that would break test 34. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=62639 -- Edit this bug report at https://bugs.php.net/bug.php?id=62639&edit=1
Bug #52520 [Fbk->NoF]: php -l errors should be reported on stderr
Edit report at https://bugs.php.net/bug.php?id=52520&edit=1 ID: 52520 Updated by: a...@php.net Reported by:lrcqqkrvry at mailinator dot com Summary:php -l errors should be reported on stderr -Status: Feedback +Status: No Feedback Type: Bug Package:Output Control PHP Version:5.3.3 Block user comment: N Private report: N New Comment: i wouldnt really expect feedback from someone using a mailinator mail :) Previous Comments: [2013-07-30 19:40:21] m...@php.net Please try using this snapshot: http://snaps.php.net/php5.4-latest.tar.gz For Windows: http://windows.php.net/snapshots/ [2010-08-03 09:00:28] lrcqqkrvry at mailinator dot com Description: ..not on stdout. Please try to understand the difference and why they are different. -- Edit this bug report at https://bugs.php.net/bug.php?id=52520&edit=1
Bug #65456 [Opn->Wfx]: Incomprehensible error message while producing a syntax error
Edit report at https://bugs.php.net/bug.php?id=65456&edit=1 ID: 65456 Updated by: ahar...@php.net Reported by:ultimateeffect at hotmail dot com Summary:Incomprehensible error message while producing a syntax error -Status: Open +Status: Wont fix Type: Bug Package:*General Issues Operating System: Ubuntu 13.04 PHP Version:5.4.17 Block user comment: N Private report: N New Comment: Recent versions of PHP include the actual ::, as your error message includes, so it should be clear where the error is (and say what you will, but T_PAAMAYIM_NEKUDOTAYIM is _very_ easy to Google). Every language needs a little quirkiness. More seriously, this has previously been discussed on Internals, and the consensus was no change: http://comments.gmane.org/gmane.comp.php.devel/62911 Marking Won't Fix. I suggest you find friendlier Rails developers. Previous Comments: [2013-08-15 15:43:34] ultimateeffect at hotmail dot com Description: T_PAAMAYIM_NEKUDOTAYIM - No one has addressed this yet even though this has been laughed at by rails developers for some time already so I am creating a ticket. Thank you. http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/ Test script: --- https://bugs.php.net/bug.php?id=65456&edit=1
Bug #65451 [Opn->Fbk]: Segmentation fault on compiling the script
Edit report at https://bugs.php.net/bug.php?id=65451&edit=1 ID: 65451 Updated by: a...@php.net Reported by:chupaka at gmail dot com Summary:Segmentation fault on compiling the script -Status: Open +Status: Feedback Type: Bug Package:Reproducible crash Operating System: Fedora 19 PHP Version:5.5.1 Block user comment: N Private report: N New Comment: About the reproduce script - any chance to get rid of GET parameters and external file dependency? Whereby it might be not that important as it crashes just compiling. I've just tried on windows and (ubuntu with and without dtrace), no crash. Maybe that's dtrace version, dunno. Is it reproduceable if you compile without dtrace support, could you please try? Previous Comments: [2013-08-14 17:09:21] chupaka at gmail dot com Description: I faced the problem after upgrading from php-5.3 to php-5.4, and now it continues in php-5.5 on Apache 2.4.6. The script (thumb.php) works correctly almost all the time (clients open webpage normally), but in Apache logs, there are messages: [Wed Aug 14 19:33:31.106671 2013] [core:notice] [pid 9968] AH00052: child pid 21804 exit signal Segmentation fault (11) [Wed Aug 14 19:33:31.106736 2013] [core:notice] [pid 9968] AH00052: child pid 23371 exit signal Segmentation fault (11) [Wed Aug 14 19:33:31.106762 2013] [core:notice] [pid 9968] AH00052: child pid 23373 exit signal Segmentation fault (11) Test script: --- thumb.php (it's the only file I saw so far that provokes segfaults): filemtime("thumbs/".$fn)) or (filesize("thumbs/".$fn) == 0)) { if (!file_exists("thumbs/".$dn)) mkdir("thumbs/".$dn); $img = imagecreatefromjpeg($fn); $size = getimagesize($fn); $nimg = imagecreatetruecolor(80, 40); imagecopyresampled($nimg, $img, 0, 0, 0, 0, 80, 40, $size[0], $size[1]); imagejpeg($nimg, "thumbs/".$fn, 85); } readfile("thumbs/".$fn); ?> Expected result: No Segmentation faults Actual result: -- gdb attached to a child shows this after failure: Program received signal SIGSEGV, Segmentation fault. 0xb6a40af2 in zend_stack_push (stack=stack@entry=0xb6c0d3d0 , element=element@entry=0xb6c0d3ac , size=size@entry=36) at /usr/src/debug/php-5.5.1/Zend/zend_stack.c:42 42 stack->elements[stack->top] = (void *) emalloc(size); (gdb) backtrace #0 0xb6a40af2 in zend_stack_push (stack=stack@entry=0xb6c0d3d0 , element=element@entry=0xb6c0d3ac , size=size@entry=36) at /usr/src/debug/php-5.5.1/Zend/zend_stack.c:42 #1 0xb6a09eca in compile_file (file_handle=file_handle@entry=0xbfa206f8, type=type@entry=2) at Zend/zend_language_scanner.l:586 #2 0xb6a30f56 in dtrace_compile_file (file_handle=0xbfa206f8, type=2) at /usr/src/debug/php-5.5.1/Zend/zend_dtrace.c:40 #3 0xb6a4390a in zend_execute_scripts (type=type@entry=2, retval=retval@entry=0x0, file_count=file_count@entry=1) at /usr/src/debug/php-5.5.1/Zend/zend.c:1308 #4 0xb6afeccf in php_handler (r=0xb9938c48) at /usr/src/debug/php-5.5.1/sapi/apache2handler/sapi_apache2.c:669 (gdb) backtrace full #0 0xb6a40af2 in zend_stack_push (stack=stack@entry=0xb6c0d3d0 , element=element@entry=0xb6c0d3ac , size=size@entry=36) at /usr/src/debug/php-5.5.1/Zend/zend_stack.c:42 No locals. #1 0xb6a09eca in compile_file (file_handle=file_handle@entry=0xbfa206f8, type=type@entry=2) at Zend/zend_language_scanner.l:586 original_lex_state = {yy_leng = 0, yy_start = 0x0, yy_text = 0x0, yy_cursor = 0x0, yy_marker = 0x0, yy_limit = 0x0, yy_state = 0, state_stack = {top = 0, max = 0, elements = 0x0}, heredoc_label_stack = {top = 0, max = 0, elements = 0x0, top_element = 0x0, persistent = 0 '\000'}, in = 0x0, lineno = 0, filename = 0x0, script_org = 0x0, script_org_size = 0, script_filtered = 0x0, script_filtered_size = 0, input_filter = 0x0, output_filter = 0x0, script_encoding = 0x0} op_array = 0xb662112c original_active_op_array = 0x0 retval = 0xb662112c compiler_result = compilation_successful = 0 '\000' retval_znode = {op_type = 1, u = {op = {constant = 1, var = 1, num = 1, hash = 1, opline_num = 1, jmp_addr = 0x1, zv = 0x1, literal = 0x1, ptr = 0x1}, constant = {value = {lval = 1, dval = -1.4312713536766795e+179, str = {val = 0x1 , len = -450778880}, ht = 0x1, obj = {handle = 1, handlers = 0xe521a900}}, refcount__gc = 1, type = 1 '\001', is_ref__gc = 0 '\000'}, op_array = 0x1}, EA = 3073921433} original_in_compilation = 0 '\000' #2 0xb6a30f56 in dtrace_compile_file (file_handle=0xbfa206f8, type=2) at /usr/src/debug/php-5.5.1/Zend/zend_dtrace.c:40 res = 0xb6621b88 #3 0xb6a439
Bug #65453 [Opn->Fbk]: Readfile() + mpg = http status 500, windows server 2008 r2 sp1, php 5.5.1
Edit report at https://bugs.php.net/bug.php?id=65453&edit=1 ID: 65453 Updated by: a...@php.net Reported by:oli dot laurel at arcor dot de Summary:Readfile() + mpg = http status 500, windows server 2008 r2 sp1, php 5.5.1 -Status: Open +Status: Feedback Type: Bug Package:IIS related Operating System: Windows Server 2008 R2 SP1 PHP Version:5.5.1 Block user comment: N Private report: N New Comment: This looks like server misconfig at first glance. In the BT there is nothing about PHP. Combined with the fact you find nothing in the error log, it might be not PHP. How did you get that BT? Debug symbols should be used for PHP as well. And when IIS starts, you should attach the debugger to the clean PHP fcgi process, so then debugger takes over. Some more points before i go try it - does the same happen when you out a plain text file instead of mpeg, also using appropriate content- type and --limit-rate? - does it happen when you request static content using wget with --limit-rate? - please post the request/response headers Thanks. Previous Comments: [2013-08-15 07:41:11] oli dot laurel at arcor dot de Description: - Installed a blank Windows Server 2008 R2 SP1 Standard, added Role IIS & Feature CGI. - Extracted 5.5.1 VC11 x86 Non Thread Safe to c:\Program Files (x86)\php - Installed vcredist_x86.exe - Configuration of IIS: added Handler Mappings in IIS Request path: *.php Module: FastCgiModule Executable: c:\Program Files (x86)\php\php-cgi.exe Name: PHP via FastCgi - Then added 2 files to C:\inetpub\wwwroot index.php & movie.mpg (6MB) - Installed wget. - No modification of php.ini, no malware scanner, ... Every time i download index.php with following script i get an HTTP-Status 500 in Access Log. [download.cmd] "C:\Program Files (x86)\GnuWin32\bin\wget.exe" --limit-rate=4 http://127.0.0.1/index.php Multiple downloads cause the server to crash and return Status 500 for every request (normal html pages, images, text files, ...). Hope backtrace helps to find the problem. Thread 6 - System ID 3884 Entry point w3tp+2040 Create time 12.08.2013 14:08:38 Time spent in user mode 0 Days 0:0:0.0 Time spent in kernel mode 0 Days 0:0:0.0 Full Call Stack Function Arg 1 Arg 2 Arg 3 Arg 4 Source ntdll!NtTerminateProcess `03212eb0 `02a7a800 `0001 ` KERNELBASE!TerminateProcess+2f `00ff6ae0 `778f598e `01c869f0 ` iisfcgi+94da `00ff3410 `00fe0cf0 `800703e3 `778c8884 iisfcgi+68aa `00ff3410 `0010 `0045d6b0 `004637e0 iisfcgi+556f ` `800703e3 `027e12f8 07fe`f5db6585 iisfcgi+105f6 ` `0002 `00fe0cf0 ` iiscore+ba3c `019d46c8 ` ` `778ac1e0 iiscore+46a4 `779a4440 `019d46c0 `019d46c8 `0001 iiscore+a775 ` `02753a30 `0008 `02753c28 iiscore+5a03 `019d46c0 `0002 `019d46c0 ` iiscore+1741 `005134d0 ` ` 07fe`f70c1107 w3dt!UlAtqGetContextProperty+a2 `005134d0 ` 07fe`faeb ` w3dt!UlAtqGetContextProperty+8c ` 07fe`fde3379b ` ` w3tp+1fba `0002 `019d3aa8 07fe`faa31080 ` w3tp+2024 ` `004be870 `004be870 07fe`faeb w3tp+20a1 ` ` ` ` kernel32!BaseThreadInitThunk+d ` ` ` ` ntdll!RtlUserThreadStart+21 ` ` ` ` Exception Information In w3wp__DefaultAppPool__PID__3596__Date__08_12_2013__Time_02_09_39PM__703__ntdll!ZwTerminateProcess.dmp the assembly instruction at ntdll!DbgBreakPoint in C:\Windows\System32\ntdll.dll from Microsoft Corporation has caused a breakpoint exception (0x8003) on thread 6 Module Information Image Name: C:\Windows\System32\ntdll.dll Symbol Type: Export Base address: 0x0003`00905a4d Time Stamp: Thu Nov 17 07:32:46 2011 Checksum: 0x` Com
[PHP-BUG] Bug #65456 [NEW]: Incomprehensible error message while producing a syntax error
From: ultimateeffect at hotmail dot com Operating system: Ubuntu 13.04 PHP version: 5.4.17 Package: *General Issues Bug Type: Bug Bug description:Incomprehensible error message while producing a syntax error Description: T_PAAMAYIM_NEKUDOTAYIM - No one has addressed this yet even though this has been laughed at by rails developers for some time already so I am creating a ticket. Thank you. http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/ Test script: --- https://bugs.php.net/bug.php?id=65456&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=65456&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=65456&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=65456&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=65456&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=65456&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=65456&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=65456&r=needscript Try newer version: https://bugs.php.net/fix.php?id=65456&r=oldversion Not developer issue:https://bugs.php.net/fix.php?id=65456&r=support Expected behavior: https://bugs.php.net/fix.php?id=65456&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=65456&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=65456&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=65456&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=65456&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=65456&r=dst IIS Stability: https://bugs.php.net/fix.php?id=65456&r=isapi Install GNU Sed:https://bugs.php.net/fix.php?id=65456&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=65456&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=65456&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=65456&r=mysqlcfg
Req #9331 [Com]: No operator overloading available
Edit report at https://bugs.php.net/bug.php?id=9331&edit=1 ID: 9331 Comment by: themastersleader at hotmail dot com Reported by:jgsmith at tamu dot edu Summary:No operator overloading available Status: Not a bug Type: Feature/Change Request Package:Feature/Change Request Operating System: Irix 6, Solaris 7, OpenBSD 2.8 PHP Version:4.0.4pl1 Block user comment: N Private report: N New Comment: I so agree with "f3n6s at objectmail dot com" I had many cases that i needed the operator overloading. Saying it will never get into the core. It's even stranger that the DateTime class is "hacked" to overload the equality operators. Previous Comments: [2012-07-03 15:01:38] ivebeenlinuxed at googlemail dot com I agree, this is a significant feature missing from PHP and this shrugging it off is really just not helpful. I cannot implement function overloads into a PHP script for a production environment if it is not included in the PHP core or default deployment packages. [2011-07-28 15:16:28] f3n6s at objectmail dot com Saying "such a feature won't go in PHP's core." Is tantamount to saying "There shall never be operator overloading in PHP" since, if it's not in the core, nobody can use it practically! Fine. Don't put it in the core. Put it on the back of a flying monkey. I don't care. But /enable/ it by default so people can use it. Second- mysterious eyebrow raising followed by "well i dunno.. thre are many problems, what if we want to vardump an array operator overloard object" and whatnot is completely backwards. You have destroyed and forgotten and thrown away everything that was once great about PHP. If such eyebrow raising had occurred when you added __get and __set, and heebee-jeebee about "proper object oriented design", then those would never have made it in. Same for a milion other features that made PHP unique and special, capable of things other languages just /couldn't do/. Third, it's been written! 575 lines of clean, simple, straightforward code sitting there on PECL. Dare-I-say, even /trivial/! And as for the comments of "oh, well, there are side effects we would have to work out..." If I don't want the side effects then I won't use the construct. __toString has /side/effects! As I said, there were things; humble things; that once made PHP great. But around the time that Zend and SPL and the rest of that junk came out, those things became less important, and PHP has incrementally become just like every other langauge out there. In response to this little gem form the "php manual user note system": - Your disdain for PHP and/or its maintainers. Go learn FORTRAN instead. Well heck, why don't we all go use JAVA if we wanna do "proper OOP". I'd much rather do cool things in half the time. /rant [2007-11-27 11:12:28] johan...@php.net There's an operator overloading extension, see pecl.php.net -> search for "operator" but such a feature won't go in PHP's core. [2007-11-27 10:51:31] C01t dot te at gmail dot com Operator overloading will open a new chapter in PHP's objects usage. And I think that perhaps it could be done through interfaces. May be included in SPL. For example interface MathOperators { function operatorAdd($object); function operatorSub($object); function operatorMul($object); function operatorDiv($object); function operatorInc($object); function operatorDec($object); } One who needs these functionality just implements this interface (or interfaces for each operation) and here it is, and operator overloading :-) [2007-08-11 07:58:14] nibujoshua at gmail dot com it is very bad, that there is no operator overloding capability for PHP The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=9331 -- Edit this bug report at https://bugs.php.net/bug.php?id=9331&edit=1
Bug #65455 [Opn->Ana]: in Unknown on line 0
Edit report at https://bugs.php.net/bug.php?id=65455&edit=1 ID: 65455 Updated by: johan...@php.net Reported by:spam2 at rhsoft dot net Summary:in Unknown on line 0 -Status: Open +Status: Analyzed Type: Bug Package:Scripting Engine problem PHP Version:5.4.17 Block user comment: N Private report: N New Comment: The error is triggered in shutdown when the user didn't clear errors by checking imap_errors(). http://lxr.php.net/xref/PHP_TRUNK/ext/imap/php_imap.c#1073 I think we could simply free the errors and be silent in this case. Users who care about errors can call imap_errors(). Previous Comments: [2013-08-15 11:25:29] spam2 at rhsoft dot net Description: $response = imap_fetch_overview($mbox, $range); Notice: Unknown: Sequence out of range (errflg=2) in Unknown on line 0 this is the same crap as https://bugs.php.net/bug.php?id=65359 and now do not tell me like in the othe rbugreport there is no script running and nobody knows file / line of the call -- Edit this bug report at https://bugs.php.net/bug.php?id=65455&edit=1
[PHP-BUG] Bug #65455 [NEW]: in Unknown on line 0
From: spam2 at rhsoft dot net Operating system: PHP version: 5.4.17 Package: Scripting Engine problem Bug Type: Bug Bug description:in Unknown on line 0 Description: $response = imap_fetch_overview($mbox, $range); Notice: Unknown: Sequence out of range (errflg=2) in Unknown on line 0 this is the same crap as https://bugs.php.net/bug.php?id=65359 and now do not tell me like in the othe rbugreport there is no script running and nobody knows file / line of the call -- Edit bug report at https://bugs.php.net/bug.php?id=65455&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=65455&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=65455&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=65455&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=65455&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=65455&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=65455&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=65455&r=needscript Try newer version: https://bugs.php.net/fix.php?id=65455&r=oldversion Not developer issue:https://bugs.php.net/fix.php?id=65455&r=support Expected behavior: https://bugs.php.net/fix.php?id=65455&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=65455&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=65455&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=65455&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=65455&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=65455&r=dst IIS Stability: https://bugs.php.net/fix.php?id=65455&r=isapi Install GNU Sed:https://bugs.php.net/fix.php?id=65455&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=65455&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=65455&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=65455&r=mysqlcfg
[PHP-BUG] Bug #65454 [NEW]: odbc_result return empty value
From: php at freakout dot de Operating system: Linux PHP version: 5.4.17 Package: ODBC related Bug Type: Bug Bug description:odbc_result return empty value Description: Without adding an weird empty printf-statement odbc_result returns empty values run with printf-statement [axel@bongo oracle]$ ./testodbc 7369 SMITH 7499 ALLEN 7521 WARD 7566 JONES 7654 MARTIN 7698 BLAKE 7782 CLARK 7788 SCOTT 7839 KING 7844 TURNER 7876 ADAMS 7900 JAMES 7902 FORD 7934 MILLER run without the statement: [axel@bongo oracle]$ ./testodbc 0 0 0 0 0 0 0 0 0 0 0 0 0 0 Test script: --- #!/opt/php/bin/php &2'); $query = "select empno, ename from emp"; $conn = odbc_connect("Oracle", "scott", "tiger"); if($result = odbc_exec($conn, $query)) { if(!$conn) die("Connection failed"); while($succ = odbc_fetch_row($result)) { // printf("%s",''); // without this statement odbc_result does not work printf("%4d %s\n", odbc_result($result, 'EMPNO'), odbc_result($result, 'ENAME')); } } ?> Expected result: 7369 SMITH 7499 ALLEN 7521 WARD 7566 JONES 7654 MARTIN 7698 BLAKE 7782 CLARK 7788 SCOTT 7839 KING 7844 TURNER 7876 ADAMS 7900 JAMES 7902 FORD 7934 MILLER Actual result: -- 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -- Edit bug report at https://bugs.php.net/bug.php?id=65454&edit=1 -- Try a snapshot (PHP 5.4): https://bugs.php.net/fix.php?id=65454&r=trysnapshot54 Try a snapshot (PHP 5.3): https://bugs.php.net/fix.php?id=65454&r=trysnapshot53 Try a snapshot (trunk): https://bugs.php.net/fix.php?id=65454&r=trysnapshottrunk Fixed in SVN: https://bugs.php.net/fix.php?id=65454&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=65454&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=65454&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=65454&r=needscript Try newer version: https://bugs.php.net/fix.php?id=65454&r=oldversion Not developer issue:https://bugs.php.net/fix.php?id=65454&r=support Expected behavior: https://bugs.php.net/fix.php?id=65454&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=65454&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=65454&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=65454&r=globals PHP 4 support discontinued: https://bugs.php.net/fix.php?id=65454&r=php4 Daylight Savings: https://bugs.php.net/fix.php?id=65454&r=dst IIS Stability: https://bugs.php.net/fix.php?id=65454&r=isapi Install GNU Sed:https://bugs.php.net/fix.php?id=65454&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=65454&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=65454&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=65454&r=mysqlcfg
Bug #64761 [Com]: rebinding of closures doesn't work when they are declared in a static method
Edit report at https://bugs.php.net/bug.php?id=64761&edit=1 ID: 64761 Comment by: wanwizard at fuelphp dot com Reported by:netmosfera at gmail dot com Summary:rebinding of closures doesn't work when they are declared in a static method Status: Wont fix Type: Bug Package:*General Issues Operating System: any PHP Version:5.5.0beta4 Block user comment: N Private report: N New Comment: I've looked into the code, and indeed, it simply bails out when you want to bind an object to the closure and it's initially created as ZEND_ACC_STATIC. So instead of if ((newthis != NULL) && (closure->func.common.fn_flags & ZEND_ACC_STATIC)) { zend_error(E_WARNING, "Cannot bind an instance to a static closure"); } it should change the scope of the closure (as the bindTo will provide an object to bind to, which implicitly changes the context of the closure. Since the closure is effectively recreated, it shouldn't be an issue changing the scope while doing that. Previous Comments: [2013-08-09 09:30:25] wanwizard at fuelphp dot com To illustrate, I now have to this to get it to work: class Dummy { public function __construct($event, $object) { // setup a shutdown event for writing cookies $event->on('shutdown', function($event) { $this->process(); }, $object); } } new Dummy($event, $instance); which does exactly the same, but now the closure is defined in an object context. Which is insane... [2013-08-09 09:02:11] wanwizard at fuelphp dot com I understand the issue of scope here, but imho the location of where the closure is not relevant. You get the same error when you do: public static function somemethod() { // construct the a new object $instance = static::factory(); // get the current event object $event = \Event::getInstance(); // setup a shutdown event $event->on('shutdown', function($event) { $this->process(); }, $instance); } where the "on" method is trying to bind $instance (which is an object, so there should be no issue, $this is defined), but fails with this same error. [2013-05-04 05:07:03] larue...@php.net as I saw, it's by design, and there are some test scripts about that: https://github.com/php/php-src/blame/master/Zend/zend_closures.c#L499 btw, why should I trun to ircmaxell? he is the author of this? [2013-05-03 23:52:51] hanskrentel at yahoo dot de @laruence: This is not by design. Please take a second look on this report. Thank you. You probably want to summon ircmaxell for help. [2013-05-03 23:44:25] netmosfera at gmail dot com makes no sense to me! also in the global scope $this isn't available, but rebind does work! The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=64761 -- Edit this bug report at https://bugs.php.net/bug.php?id=64761&edit=1
[PHP-BUG] Bug #65453 [NEW]: Readfile() + mpg = http status 500, windows server 2008 r2 sp1, php 5.5.1
From: oli dot laurel at arcor dot de Operating system: Windows Server 2008 R2 SP1 PHP version: 5.5.1 Package: IIS related Bug Type: Bug Bug description:Readfile() + mpg = http status 500, windows server 2008 r2 sp1, php 5.5.1 Description: - Installed a blank Windows Server 2008 R2 SP1 Standard, added Role IIS & Feature CGI. - Extracted 5.5.1 VC11 x86 Non Thread Safe to c:\Program Files (x86)\php - Installed vcredist_x86.exe - Configuration of IIS: added Handler Mappings in IIS Request path: *.php Module: FastCgiModule Executable: c:\Program Files (x86)\php\php-cgi.exe Name: PHP via FastCgi - Then added 2 files to C:\inetpub\wwwroot index.php & movie.mpg (6MB) - Installed wget. - No modification of php.ini, no malware scanner, ... Every time i download index.php with following script i get an HTTP-Status 500 in Access Log. [download.cmd] "C:\Program Files (x86)\GnuWin32\bin\wget.exe" --limit-rate=4 http://127.0.0.1/index.php Multiple downloads cause the server to crash and return Status 500 for every request (normal html pages, images, text files, ...). Hope backtrace helps to find the problem. Thread 6 - System ID 3884 Entry point w3tp+2040 Create time 12.08.2013 14:08:38 Time spent in user mode 0 Days 0:0:0.0 Time spent in kernel mode 0 Days 0:0:0.0 Full Call Stack Function Arg 1 Arg 2 Arg 3 Arg 4 Source ntdll!NtTerminateProcess `03212eb0 `02a7a800 `0001 ` KERNELBASE!TerminateProcess+2f `00ff6ae0 `778f598e `01c869f0 ` iisfcgi+94da `00ff3410 `00fe0cf0 `800703e3 `778c8884 iisfcgi+68aa `00ff3410 `0010 `0045d6b0 `004637e0 iisfcgi+556f ` `800703e3 `027e12f8 07fe`f5db6585 iisfcgi+105f6 ` `0002 `00fe0cf0 ` iiscore+ba3c `019d46c8 ` ` `778ac1e0 iiscore+46a4 `779a4440 `019d46c0 `019d46c8 `0001 iiscore+a775 ` `02753a30 `0008 `02753c28 iiscore+5a03 `019d46c0 `0002 `019d46c0 ` iiscore+1741 `005134d0 ` ` 07fe`f70c1107 w3dt!UlAtqGetContextProperty+a2 `005134d0 ` 07fe`faeb ` w3dt!UlAtqGetContextProperty+8c ` 07fe`fde3379b ` ` w3tp+1fba `0002 `019d3aa8 07fe`faa31080 ` w3tp+2024 ` `004be870 `004be870 07fe`faeb w3tp+20a1 ` ` ` ` kernel32!BaseThreadInitThunk+d ` ` ` ` ntdll!RtlUserThreadStart+21 ` ` ` ` Exception Information In w3wp__DefaultAppPool__PID__3596__Date__08_12_2013__Time_02_09_39PM__703__ntdll!ZwTerminateProcess.dmp the assembly instruction at ntdll!DbgBreakPoint in C:\Windows\System32\ntdll.dll from Microsoft Corporation has caused a breakpoint exception (0x8003) on thread 6 Module Information Image Name: C:\Windows\System32\ntdll.dll Symbol Type: Export Base address: 0x0003`00905a4d Time Stamp: Thu Nov 17 07:32:46 2011 Checksum: 0x` Comments: COM DLL: False Company Name: Microsoft Corporation ISAPIExtension: False File Description: NT Layer DLL ISAPIFilter: False File Version: 6.1.7601.17725 (win7sp1_gdr.16-1503) 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,66 MBytes Product Version: 6.1.7601.17725 Symbol File Name: ntdll.dll Special Build: & Test script: --- [index.php] [download.cmd] "C:\Program Files (x86)\GnuWin32\bin\wget.exe" --limit-rate=4 http://127.0.0.1/index.php Expected result: HTTP Status in Access-Log of IIS should be 200 Actual result: -- Every time file is downloaded with "--limit-rate=4" Access Log show HTTP Status 500. No entries can by found in php Log. -- Edit bug report at https://bugs.php.n