Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/zlib/tests/bug61139.phpt ext/zlib/zlib_fopen_wrapper.c
Why is this test creating the file in the root directory? And should it be created at all since the function fails? -Hannes On Fri, Mar 2, 2012 at 15:16, Nikita Popov ni...@php.net wrote: nikic Fri, 02 Mar 2012 14:16:47 + Revision: http://svn.php.net/viewvc?view=revisionrevision=323819 Log: Merge: Fix bug #61139: gzopen leaks when specifying invalid mode Bug: https://bugs.php.net/61139 (Assigned) gzopen leaks when specifying invalid mode Changed paths: U php/php-src/branches/PHP_5_4/NEWS A php/php-src/branches/PHP_5_4/ext/zlib/tests/bug61139.phpt U php/php-src/branches/PHP_5_4/ext/zlib/zlib_fopen_wrapper.c Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2012-03-02 14:08:11 UTC (rev 323818) +++ php/php-src/branches/PHP_5_4/NEWS 2012-03-02 14:16:47 UTC (rev 323819) @@ -43,6 +43,9 @@ - XMLRPC: . Fixed bug #61097 (Memory leak in xmlrpc functions copying zvals). (Nikita Popov) +- Zlib: + . Fixed bug #61139 (gzopen leaks when specifying invalid mode). (Nikita Popov) + 01 Mar 2012, PHP 5.4.0 - Installation: Added: php/php-src/branches/PHP_5_4/ext/zlib/tests/bug61139.phpt === --- php/php-src/branches/PHP_5_4/ext/zlib/tests/bug61139.phpt (rev 0) +++ php/php-src/branches/PHP_5_4/ext/zlib/tests/bug61139.phpt 2012-03-02 14:16:47 UTC (rev 323819) @@ -0,0 +1,14 @@ +--TEST-- +Bug #61139 (gzopen leaks when specifying invalid mode) +--SKIPIF-- +?php +if (!extension_loaded('zlib')) { + die('skip - zlib extension not loaded'); +} +? +--FILE-- +?php + +gzopen('someFile', 'c'); +--EXPECTF-- +Warning: gzopen(): gzopen failed in %s on line %d Modified: php/php-src/branches/PHP_5_4/ext/zlib/zlib_fopen_wrapper.c === --- php/php-src/branches/PHP_5_4/ext/zlib/zlib_fopen_wrapper.c 2012-03-02 14:08:11 UTC (rev 323818) +++ php/php-src/branches/PHP_5_4/ext/zlib/zlib_fopen_wrapper.c 2012-03-02 14:16:47 UTC (rev 323819) @@ -109,7 +109,7 @@ php_stream *php_stream_gzopen(php_stream_wrapper *wrapper, char *path, char *mode, int options, char **opened_path, php_stream_context *context STREAMS_DC TSRMLS_DC) { - struct php_gz_stream_data_t *self = {0}; + struct php_gz_stream_data_t *self; php_stream *stream = NULL, *innerstream = NULL; /* sanity check the stream: it can be either read-only or write-only */ @@ -120,8 +120,6 @@ return NULL; } - self = emalloc(sizeof(*self)); - if (strncasecmp(compress.zlib://, path, 16) == 0) { path += 16; } else if (strncasecmp(zlib:, path, 5) == 0) { @@ -134,32 +132,29 @@ int fd; if (SUCCESS == php_stream_cast(innerstream, PHP_STREAM_AS_FD, (void **) fd, REPORT_ERRORS)) { - self-gz_file = gzdopen(dup(fd), mode); + self = emalloc(sizeof(*self)); self-stream = innerstream; - if (self-gz_file) { + self-gz_file = gzdopen(dup(fd), mode); + + if (self-gz_file) { stream = php_stream_alloc_rel(php_stream_gzio_ops, self, 0, mode); if (stream) { stream-flags |= PHP_STREAM_FLAG_NO_BUFFER; return stream; } + gzclose(self-gz_file); } + + efree(self); if (options REPORT_ERRORS) { php_error_docref(NULL TSRMLS_CC, E_WARNING, gzopen failed); } - } else if (innerstream) { - php_stream_close(innerstream); } - } - if (stream) { - php_stream_close(stream); + php_stream_close(innerstream); } - - if (self) { - efree(self); - } - + return NULL; } -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS
Hi Nikic: just FYI, I was told that, the entries in NEWS should be in desc order(in a category) by bug id :) thanks On Fri, Mar 2, 2012 at 4:25 PM, Nikita Popov ni...@php.net wrote: nikic Fri, 02 Mar 2012 08:25:28 + Revision: http://svn.php.net/viewvc?view=revisionrevision=323805 Log: Forgot NEWS for r323803 Changed paths: U php/php-src/branches/PHP_5_4/NEWS Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2012-03-02 08:21:54 UTC (rev 323804) +++ php/php-src/branches/PHP_5_4/NEWS 2012-03-02 08:25:28 UTC (rev 323805) @@ -20,6 +20,7 @@ . Fixed bug #60801 (strpbrk() mishandles NUL byte). (Adam) . Fixed bug #60573 (type hinting with self keyword causes weird errors). (Laruence) + . Fixed bug #61106 (Segfault when using header_register_callback). (Nikita Popov) - Standard: . Fixed memory leak in substr_replace. (Pierrick) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Laruence Xinchen Hui http://www.laruence.com/ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/string.c
On 03/01/2012 07:10 PM, Pierrick Charron wrote: pierrick Thu, 01 Mar 2012 15:10:29 + Revision: http://svn.php.net/viewvc?view=revisionrevision=323710 Log: Fixed memory leak in substr_replace +test ? -- Wbr, Antony Dovgal --- http://pinba.org - realtime profiling for PHP -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/string.c
Test for bug #55871 is already covering this issue. P. On 1 March 2012 11:35, Antony Dovgal t...@daylessday.org wrote: On 03/01/2012 07:10 PM, Pierrick Charron wrote: pierrick Thu, 01 Mar 2012 15:10:29 + Revision: http://svn.php.net/viewvc?view=revisionrevision=323710 Log: Fixed memory leak in substr_replace +test ? -- Wbr, Antony Dovgal --- http://pinba.org - realtime profiling for PHP -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS
Stas, Some of those bug fixes listed under 5.4.0 are already fixed in 5.3.10. Random examples include the OCI8 fixes, OpenSSL fix 60279, Tidy fix 54682, and CURL fix 60439. Do you need a hand sorting out the dups? Chris On 02/28/2012 04:50 PM, Stanislav Malyshev wrote: stas Wed, 29 Feb 2012 00:50:00 + Revision: http://svn.php.net/viewvc?view=revisionrevision=323645 Log: prepare NEWS for 5.4.0 Changed paths: U php/php-src/branches/PHP_5_4/NEWS -- Email: christopher.jo...@oracle.com Tel: +1 650 506 8630 Blog: http://blogs.oracle.com/opal/ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/Zend.m4 branches/PHP_5_4/Zend/zend.h branches/PHP_5_4/main/main.c trunk/Zend/Zend.m4 trunk/Zend/zend.h trunk/main/main.c
On 02/15/2012 05:51 PM, Stanislav Malyshev wrote: stas Thu, 16 Feb 2012 01:51:45 + Revision: http://svn.php.net/viewvc?view=revisionrevision=323245 Log: make ZEND_SIGNALS configurable, off by default also make ZEND_SIGNALS enabled and disabled binary-compatible Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/Zend/Zend.m4 U php/php-src/branches/PHP_5_4/Zend/zend.h U php/php-src/branches/PHP_5_4/main/main.c U php/php-src/trunk/Zend/Zend.m4 U php/php-src/trunk/Zend/zend.h U php/php-src/trunk/main/main.c Did you run the tests? Just from a quick skim I think this would break both the pcntl and the posix extension. -Rasmus -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/Zend.m4 branches/PHP_5_4/Zend/zend.h branches/PHP_5_4/main/main.c trunk/Zend/Zend.m4 trunk/Zend/zend.h trunk/main/main.c
On 02/15/2012 08:52 PM, Rasmus Lerdorf wrote: On 02/15/2012 05:51 PM, Stanislav Malyshev wrote: stas Thu, 16 Feb 2012 01:51:45 + Revision: http://svn.php.net/viewvc?view=revisionrevision=323245 Log: make ZEND_SIGNALS configurable, off by default also make ZEND_SIGNALS enabled and disabled binary-compatible Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/Zend/Zend.m4 U php/php-src/branches/PHP_5_4/Zend/zend.h U php/php-src/branches/PHP_5_4/main/main.c U php/php-src/trunk/Zend/Zend.m4 U php/php-src/trunk/Zend/zend.h U php/php-src/trunk/main/main.c Did you run the tests? Just from a quick skim I think this would break both the pcntl and the posix extension. ok, the pcntl test failures were due to the API bump and not having recompiled shared extensions that rely on zend_signals posix seems ok -Rasmus -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/Zend.m4 branches/PHP_5_4/Zend/zend.h branches/PHP_5_4/main/main.c trunk/Zend/Zend.m4 trunk/Zend/zend.h trunk/main/main.c
Hi! Did you run the tests? Just from a quick skim I think this would break both the pcntl and the posix extension. Yes, I did - no (new) fails both on Mac and Linux. If you see any please tell me. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/html.c ext/standard/tests/strings/bug60965.phpt
I didn't carefully review this patch, but doesn't this code suffer from potential math overflow? i.e. with strlen($input_str) INT_MAX/2 (or UINT_MAX/2) Nuno - Original Message - From: Gustavo André dos Santos Lopes cataphr...@php.net To: php-cvs@lists.php.net Sent: Sunday, February 05, 2012 9:59 AM Subject: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/html.c ext/standard/tests/strings/bug60965.phpt cataphract Sun, 05 Feb 2012 09:59:33 + Revision: http://svn.php.net/viewvc?view=revisionrevision=323074 Log: - Merge r323056 (see bug #60965). Bug: https://bugs.php.net/60965 (Critical) Buffer overflow on htmlspecialchars/entities with $double=false Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/ext/standard/html.c A + php/php-src/branches/PHP_5_4/ext/standard/tests/strings/bug60965.phpt (from php/php-src/trunk/ext/standard/tests/strings/bug60965.phpt:r323056) Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2012-02-05 09:58:50 UTC (rev 323073) +++ php/php-src/branches/PHP_5_4/NEWS 2012-02-05 09:59:33 UTC (rev 323074) @@ -1,10 +1,13 @@ PHP NEWS ||| ?? Feb 2012, PHP 5.4.0 RC 8 +- Core: + . Fixed bug #60965 (Buffer overflow on htmlspecialchars/entities with +$double=false). (Gustavo) 02 Feb 2012, PHP 5.4.0 RC 7 - Core: - . Fix bug #60895 (Possible invalid handler usage in windows random + . Fixed bug #60895 (Possible invalid handler usage in windows random functions). (Pierre) . Fixed bug #51860 (Include fails with toplevel symlink to /). (Dmitry) . Fixed (disabled) inline-caching for ZEND_OVERLOADED_FUNCTION methods. Modified: php/php-src/branches/PHP_5_4/ext/standard/html.c === --- php/php-src/branches/PHP_5_4/ext/standard/html.c 2012-02-05 09:58:50 UTC (rev 323073) +++ php/php-src/branches/PHP_5_4/ext/standard/html.c 2012-02-05 09:59:33 UTC (rev 323074) @@ -1215,7 +1215,6 @@ size_t cursor, maxlen, len; char *replaced; enum entity_charset charset = determine_charset(hint_charset TSRMLS_CC); - int matches_map; int doctype = flags ENT_HTML_DOC_TYPE_MASK; entity_table_opt entity_table; const enc_to_uni *to_uni_table = NULL; @@ -1253,12 +1252,14 @@ } } + /* initial estimate */ if (oldlen 64) { maxlen = 128; } else { maxlen = 2 * oldlen; } - replaced = emalloc(maxlen); + + replaced = emalloc(maxlen + 1); len = 0; cursor = 0; while (cursor oldlen) { @@ -1271,7 +1272,7 @@ /* guarantee we have at least 40 bytes to write. * In HTML5, entities may take up to 33 bytes */ if (len + 40 maxlen) { - replaced = erealloc(replaced, maxlen += 128); + replaced = erealloc(replaced, (maxlen += 128) + 1); } if (status == FAILURE) { @@ -1291,7 +1292,6 @@ mbsequence = old[cursor_before]; mbseqlen = cursor - cursor_before; } - matches_map = 0; if (this_char != '') { /* no entity on this position */ const unsigned char *rep = NULL; @@ -1302,12 +1302,15 @@ goto pass_char_through; if (all) { /* false that CHARSET_PARTIAL_SUPPORT(charset) */ - /* look for entity for this char */ if (to_uni_table != NULL) { + /* !CHARSET_UNICODE_COMPAT therefore not UTF-8; since UTF-8 + * is the only multibyte encoding with !CHARSET_PARTIAL_SUPPORT, + * we're using a single byte encoding */ map_to_unicode(this_char, to_uni_table, this_char); if (this_char == 0x) /* no mapping; pass through */ goto pass_char_through; } + /* the cursor may advance */ find_entity_for_char(this_char, charset, entity_table.ms_table, rep, rep_len, old, oldlen, cursor); } else { @@ -1397,6 +1400,10 @@ } } /* checks passed; copy entity to result */ + /* entity size is unbounded, we may need more memory */ + if (maxlen len + ent_len + 2 /* and ; */) { + replaced = erealloc(replaced, (maxlen += ent_len + 128) + 1); + } replaced[len++] = ''; memcpy(replaced[len], old[cursor], ent_len); len += ent_len; Copied: php/php-src/branches/PHP_5_4/ext/standard/tests/strings/bug60965.phpt (from rev 323056, php/php-src/trunk/ext/standard/tests/strings/bug60965.phpt) === --- php/php-src/branches/PHP_5_4/ext/standard/tests/strings/bug60965.phpt (rev 0) +++ php/php-src/branches/PHP_5_4/ext/standard/tests/strings/bug60965.phpt 2012-02-05 09:59:33 UTC (rev 323074) @@ -0,0 +1,10 @@ +--TEST-- +Bug #60965: Buffer overflow on htmlspecialchars/entities with $double=false +--FILE-- +?php +echo htmlspecialchars('#x05;', +ENT_QUOTES, 'UTF-8', false), \n; +echo Done.\n; +--EXPECT--
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/html.c ext/standard/tests/strings/bug60965.phpt
On Sun, 5 Feb 2012 10:55:39 -, Nuno Lopes wrote: I didn't carefully review this patch, but doesn't this code suffer from potential math overflow? i.e. with strlen($input_str) INT_MAX/2 (or UINT_MAX/2) All the length and position variables are of type size_t, so I'd say we'd be out of memory long before that could be a problem (unless there's some architecture of which I'm not aware where SIZE_T is low enough for this to be a problem). -- Gustavo Lopes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/html.c ext/standard/tests/strings/bug60965.phpt
On Sun, 05 Feb 2012 14:00:11 +0100, Gustavo Lopes wrote: On Sun, 5 Feb 2012 10:55:39 -, Nuno Lopes wrote: I didn't carefully review this patch, but doesn't this code suffer from potential math overflow? i.e. with strlen($input_str) INT_MAX/2 (or UINT_MAX/2) All the length and position variables are of type size_t, so I'd say we'd be out of memory long before that could be a problem (unless there's some architecture of which I'm not aware where SIZE_T is low enough for this to be a problem). read: SIZE_MAX, not SIZE_T -- Gustavo Lopes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/html.c ext/standard/tests/strings/bug60965.phpt
2012/2/5 Gustavo Lopes glo...@nebm.ist.utl.pt: All the length and position variables are of type size_t, so I'd say we'd be out of memory long before that could be a problem (unless there's some architecture of which I'm not aware where SIZE_T is low enough for this to be a problem). read: SIZE_MAX, not SIZE_T By the way, SIZE_MAX (can be up to 65k or so afair) should not be used in relation with buffer (string or other) length. It defines the maximum size of a single object allocation that the compiler can manage. Not sure if it is actually what you want here. -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/html.c ext/standard/tests/strings/bug60965.phpt
On Sun, 5 Feb 2012 14:37:27 +0100, Pierre Joye wrote: 2012/2/5 Gustavo Lopes glo...@nebm.ist.utl.pt: All the length and position variables are of type size_t, so I'd say we'd be out of memory long before that could be a problem (unless there's some architecture of which I'm not aware where SIZE_T is low enough for this to be a problem). read: SIZE_MAX, not SIZE_T By the way, SIZE_MAX (can be up to 65k or so afair) should not be used in relation with buffer (string or other) length. It defines the maximum size of a single object allocation that the compiler can manage. Not sure if it is actually what you want here. SIZE_MAX is indeed the limit of size_t. See ISO/IEC 9899:TC3, section 7.18.3 on http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1124.pdf (page 259). Forgetting the irrelevant case where size_t is 16 bit wide, there is indeed a potential problem if size_t is 32-bit wide. First, if you can pass a string with about 2GB you could the multiplication by 2 would wrap around. But you could even pass a smaller string (possibly 10/15 times less, I don't know what's the maximum expansion factor of htmlentities) and then it could wrap in the reallocation. I'll take this into account. -- Gustavo Lopes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/html.c ext/standard/tests/strings/bug60965.phpt
On Sun, 05 Feb 2012 15:00:11 +0100, Gustavo Lopes wrote: On Sun, 5 Feb 2012 14:37:27 +0100, Pierre Joye wrote: 2012/2/5 Gustavo Lopes glo...@nebm.ist.utl.pt: All the length and position variables are of type size_t, so I'd say we'd be out of memory long before that could be a problem (unless there's some architecture of which I'm not aware where SIZE_T is low enough for this to be a problem). read: SIZE_MAX, not SIZE_T By the way, SIZE_MAX (can be up to 65k or so afair) should not be used in relation with buffer (string or other) length. It defines the maximum size of a single object allocation that the compiler can manage. Not sure if it is actually what you want here. SIZE_MAX is indeed the limit of size_t. See ISO/IEC 9899:TC3, section 7.18.3 on http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1124.pdf (page 259). Forgetting the irrelevant case where size_t is 16 bit wide, there is indeed a potential problem if size_t is 32-bit wide. First, if you can pass a string with about 2GB you could the multiplication by 2 would wrap around. But you could even pass a smaller string (possibly 10/15 times less, I don't know what's the maximum expansion factor of htmlentities) and then it could wrap in the reallocation. I'll take this into account. See http://svn.php.net/viewvc/php/php-src/trunk/ext/standard/html.c?r1=323079r2=323078pathrev=323079 I don't know if this is worth merging to 5.4 at this point; after all 5.3 has the same problem. -- Gustavo Lopes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/html.c ext/standard/tests/strings/bug60965.phpt
On Sun, 05 Feb 2012 15:00:11 +0100, Gustavo Lopes wrote: On Sun, 5 Feb 2012 14:37:27 +0100, Pierre Joye wrote: 2012/2/5 Gustavo Lopes glo...@nebm.ist.utl.pt: All the length and position variables are of type size_t, so I'd say we'd be out of memory long before that could be a problem (unless there's some architecture of which I'm not aware where SIZE_T is low enough for this to be a problem). read: SIZE_MAX, not SIZE_T By the way, SIZE_MAX (can be up to 65k or so afair) should not be used in relation with buffer (string or other) length. It defines the maximum size of a single object allocation that the compiler can manage. Not sure if it is actually what you want here. SIZE_MAX is indeed the limit of size_t. See ISO/IEC 9899:TC3, section 7.18.3 on http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1124.pdf (page 259). Forgetting the irrelevant case where size_t is 16 bit wide, there is indeed a potential problem if size_t is 32-bit wide. First, if you can pass a string with about 2GB you could the multiplication by 2 would wrap around. But you could even pass a smaller string (possibly 10/15 times less, I don't know what's the maximum expansion factor of htmlentities) and then it could wrap in the reallocation. I'll take this into account. See http://svn.php.net/viewvc/php/php-src/trunk/ext/standard/html.c?r1=323079r2=323078pathrev=323079 I don't know if this is worth merging to 5.4 at this point; after all 5.3 has the same problem. Obrigado! I think this bug (although probably exploitable) is low risk, since it requires a large 'memory_limit' value to be triggable. Your last patch seems good to me. Nuno -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/acinclude.m4 trunk/acinclude.m4
Uhm, I don't think this change makes much sense (nor does the previous behaviour on Mac).. Extensions that use C++ should pull in the required libraries themselves. We shouldn't be linking PHP everytime with libstdc++ if that is not needed. Nuno - Original Message - bjoriTue, 27 Dec 2011 13:53:11 + Revision: http://svn.php.net/viewvc?view=revisionrevision=321435 Log: Looks like we need to explicity add libstdc++ on recent linux' too, like fedora 14 and ubuntu 11 This fixes build failures for ext/intl and several pecl exts Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/acinclude.m4 U php/php-src/trunk/acinclude.m4 Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-12-27 11:05:58 UTC (rev 321434) +++ php/php-src/branches/PHP_5_4/NEWS 2011-12-27 13:53:11 UTC (rev 321435) @@ -7,6 +7,10 @@ - CLI SAPI: . Fixed bug #60591 (Memory leak when access a non-exists file). (Laruence) +- Intl: + . Fixed build on Fedora 15 / Ubuntu 11. (Hannes) + + 22 Dec 2011, PHP 5.4.0 RC4 - Core: . Added max_input_vars directive to prevent attacks based on hash collisions Modified: php/php-src/branches/PHP_5_4/acinclude.m4 === --- php/php-src/branches/PHP_5_4/acinclude.m4 2011-12-27 11:05:58 UTC (rev 321434) +++ php/php-src/branches/PHP_5_4/acinclude.m4 2011-12-27 13:53:11 UTC (rev 321435) @@ -762,11 +762,7 @@ if test -z $php_cxx_done; then AC_PROG_CXX AC_PROG_CXXCPP -case $host_alias in - *darwin*) -PHP_ADD_LIBRARY(stdc++) - ;; -esac +PHP_ADD_LIBRARY(stdc++) php_cxx_done=yes fi ]) Modified: php/php-src/trunk/acinclude.m4 === --- php/php-src/trunk/acinclude.m4 2011-12-27 11:05:58 UTC (rev 321434) +++ php/php-src/trunk/acinclude.m4 2011-12-27 13:53:11 UTC (rev 321435) @@ -762,11 +762,7 @@ if test -z $php_cxx_done; then AC_PROG_CXX AC_PROG_CXXCPP -case $host_alias in - *darwin*) -PHP_ADD_LIBRARY(stdc++) - ;; -esac +PHP_ADD_LIBRARY(stdc++) php_cxx_done=yes fi ]) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/acinclude.m4 trunk/acinclude.m4
On Tue, Dec 27, 2011 at 18:02, Nuno Lopes nlop...@php.net wrote: Uhm, I don't think this change makes much sense (nor does the previous behaviour on Mac).. Extensions that use C++ should pull in the required libraries themselves. We shouldn't be linking PHP everytime with libstdc++ if that is not needed. Then what is the idea behind PHP_REQUIRE_CXX? As I see it, it should pull in everything needed for the extension to use c++. -Hannes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/acinclude.m4 trunk/acinclude.m4
On Tue, Dec 27, 2011 at 18:02, Nuno Lopes nlop...@php.net wrote: Uhm, I don't think this change makes much sense (nor does the previous behaviour on Mac).. Extensions that use C++ should pull in the required libraries themselves. We shouldn't be linking PHP everytime with libstdc++ if that is not needed. Then what is the idea behind PHP_REQUIRE_CXX? As I see it, it should pull in everything needed for the extension to use c++. Ah, sorry, I was fooled by your commit message.. I didn't noticed your change was in PHP_REQUIRE_CXX. Anyway, pulling libstdc++ is a bit too gcc centric. If I use, say, clang, then I may want to use libc++ instead. The right fix, I believe, is to change the link command to use $CXX instead of $CC, since the c++ compiler knows which libraries it needs. For example, it seems that PHP_SHARED_MODULE is doing the right thing. Nuno -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/zend_compile.c branches/PHP_5_4/Zend/zend_object_handlers.c trunk/Zend/zend_compile.c trunk/Zend/zend_object_handlers.c
Hi: Thanks guys! I have only briefly rechecked the code, and dont remember at the moment how the default property table works, but for me it feels like these offsets are also incorrect for public or protected stuff that gets newly added to the class? Best regards Stefan On 19 Dec 2011, at 17:48, Xinchen Hui wrote: laruence Mon, 19 Dec 2011 16:48:18 + Revision: http://svn.php.net/viewvc?view=revisionrevision=321166 Log: Fixed bug #60558 (Invalid read and writes) Re-Fixed bug #60536 (Traits Segfault) #Thanks to tony2001, I found the previous fix -r321089 is actually not a correct one. #The key problem there is because the traits didn't correct set the property_info.offset #for private properties. so here come the new fix. Bugs: https://bugs.php.net/60558 (Re-Opened) Invalid read and writes https://bugs.php.net/60536 (Closed) Traits Segfault Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/Zend/zend_compile.c U php/php-src/branches/PHP_5_4/Zend/zend_object_handlers.c U php/php-src/trunk/Zend/zend_compile.c U php/php-src/trunk/Zend/zend_object_handlers.c svn-diffs-321166.txt-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Stefan Marr Software Languages Lab Vrije Universiteit Brussel Pleinlaan 2 / B-1050 Brussels / Belgium http://soft.vub.ac.be/~smarr Phone: +32 2 629 2974 Fax: +32 2 629 3525 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/zend_compile.c branches/PHP_5_4/Zend/zend_object_handlers.c trunk/Zend/zend_compile.c trunk/Zend/zend_object_handlers.c
Hi: For public and protected properties, you will have only one copy in the child class, so there is no such conflict. Thanks Sent from my iPhone 在 2011-12-20,1:12,Stefan Marr p...@stefan-marr.de 写道: Hi: Thanks guys! I have only briefly rechecked the code, and dont remember at the moment how the default property table works, but for me it feels like these offsets are also incorrect for public or protected stuff that gets newly added to the class? Best regards Stefan On 19 Dec 2011, at 17:48, Xinchen Hui wrote: laruence Mon, 19 Dec 2011 16:48:18 + Revision: http://svn.php.net/viewvc?view=revisionrevision=321166 Log: Fixed bug #60558 (Invalid read and writes) Re-Fixed bug #60536 (Traits Segfault) #Thanks to tony2001, I found the previous fix -r321089 is actually not a correct one. #The key problem there is because the traits didn't correct set the property_info.offset #for private properties. so here come the new fix. Bugs: https://bugs.php.net/60558 (Re-Opened) Invalid read and writes https://bugs.php.net/60536 (Closed) Traits Segfault Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/Zend/zend_compile.c U php/php-src/branches/PHP_5_4/Zend/zend_object_handlers.c U php/php-src/trunk/Zend/zend_compile.c U php/php-src/trunk/Zend/zend_object_handlers.c svn-diffs-321166.txt-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Stefan Marr Software Languages Lab Vrije Universiteit Brussel Pleinlaan 2 / B-1050 Brussels / Belgium http://soft.vub.ac.be/~smarr Phone: +32 2 629 2974 Fax: +32 2 629 3525 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/zend_compile.c branches/PHP_5_4/Zend/zend_object_handlers.c trunk/Zend/zend_compile.c trunk/Zend/zend_object_handlers.c
s/class/object/ Sent from my iPhone 在 2011-12-20,9:29,Xinchen Hui larue...@gmail.com 写道: Hi: For public and protected properties, you will have only one copy in the child class, so there is no such conflict. Thanks Sent from my iPhone 在 2011-12-20,1:12,Stefan Marr p...@stefan-marr.de 写道: Hi: Thanks guys! I have only briefly rechecked the code, and dont remember at the moment how the default property table works, but for me it feels like these offsets are also incorrect for public or protected stuff that gets newly added to the class? Best regards Stefan On 19 Dec 2011, at 17:48, Xinchen Hui wrote: laruence Mon, 19 Dec 2011 16:48:18 + Revision: http://svn.php.net/viewvc?view=revisionrevision=321166 Log: Fixed bug #60558 (Invalid read and writes) Re-Fixed bug #60536 (Traits Segfault) #Thanks to tony2001, I found the previous fix -r321089 is actually not a correct one. #The key problem there is because the traits didn't correct set the property_info.offset #for private properties. so here come the new fix. Bugs: https://bugs.php.net/60558 (Re-Opened) Invalid read and writes https://bugs.php.net/60536 (Closed) Traits Segfault Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/Zend/zend_compile.c U php/php-src/branches/PHP_5_4/Zend/zend_object_handlers.c U php/php-src/trunk/Zend/zend_compile.c U php/php-src/trunk/Zend/zend_object_handlers.c svn-diffs-321166.txt-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Stefan Marr Software Languages Lab Vrije Universiteit Brussel Pleinlaan 2 / B-1050 Brussels / Belgium http://soft.vub.ac.be/~smarr Phone: +32 2 629 2974 Fax: +32 2 629 3525 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/main/main.c branches/PHP_5_4/main/php_globals.h branches/PHP_5_4/main/php_variables.c trunk/main/main.c trunk/main/php_globals.h
hi Dmitry, Please add a note to the UPGRADING guide as well. Thanks, On Wed, Dec 14, 2011 at 9:56 AM, Dmitry Stogov dmi...@php.net wrote: dmitry Wed, 14 Dec 2011 08:56:35 + Revision: http://svn.php.net/viewvc?view=revisionrevision=321003 Log: Added max_input_vars directive to prevent attacks based on hash collisions Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/main/main.c U php/php-src/branches/PHP_5_4/main/php_globals.h U php/php-src/branches/PHP_5_4/main/php_variables.c U php/php-src/trunk/main/main.c U php/php-src/trunk/main/php_globals.h U php/php-src/trunk/main/php_variables.c Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-12-14 04:02:56 UTC (rev 321002) +++ php/php-src/branches/PHP_5_4/NEWS 2011-12-14 08:56:35 UTC (rev 321003) @@ -1,6 +1,9 @@ PHP NEWS ||| ?? Dec 2011, PHP 5.4.0 RC4 +- Core: + . Added max_input_vars directive to prevent attacks based on hash collisions + (Dmitry). - CLI SAPI: . Fixed bug #60477 (Segfault after two multipart/form-data POST requests, one 200 RQ and one 404). (Laruence) @@ -9,6 +12,8 @@ 08 Dec 2011, PHP 5.4.0 RC3 - Core: + . Fixed bug #60444 (Segmentation fault with include class extending). + (Laruence, Dmitry). . Fixed bug #60350 (No string escape code for ESC (ascii 27), normally \e). (php at mickweiss dot com) . Fixed bug #60240 (invalid read/writes when unserializing specially crafted Modified: php/php-src/branches/PHP_5_4/main/main.c === --- php/php-src/branches/PHP_5_4/main/main.c 2011-12-14 04:02:56 UTC (rev 321002) +++ php/php-src/branches/PHP_5_4/main/main.c 2011-12-14 08:56:35 UTC (rev 321003) @@ -531,6 +531,7 @@ STD_PHP_INI_ENTRY(post_max_size, 8M, PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateLong, post_max_size, sapi_globals_struct,sapi_globals) STD_PHP_INI_ENTRY(upload_tmp_dir, NULL, PHP_INI_SYSTEM, OnUpdateStringUnempty, upload_tmp_dir, php_core_globals, core_globals) STD_PHP_INI_ENTRY(max_input_nesting_level, 64, PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateLongGEZero, max_input_nesting_level, php_core_globals, core_globals) + STD_PHP_INI_ENTRY(max_input_vars, 1000, PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateLongGEZero, max_input_vars, php_core_globals, core_globals) STD_PHP_INI_ENTRY(user_dir, NULL, PHP_INI_SYSTEM, OnUpdateString, user_dir, php_core_globals, core_globals) STD_PHP_INI_ENTRY(variables_order, EGPCS, PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateStringUnempty, variables_order, php_core_globals, core_globals) Modified: php/php-src/branches/PHP_5_4/main/php_globals.h === --- php/php-src/branches/PHP_5_4/main/php_globals.h 2011-12-14 04:02:56 UTC (rev 321002) +++ php/php-src/branches/PHP_5_4/main/php_globals.h 2011-12-14 08:56:35 UTC (rev 321003) @@ -146,6 +146,7 @@ zend_bool com_initialized; #endif long max_input_nesting_level; + long max_input_vars; zend_bool in_user_include; char *user_ini_filename; Modified: php/php-src/branches/PHP_5_4/main/php_variables.c === --- php/php-src/branches/PHP_5_4/main/php_variables.c 2011-12-14 04:02:56 UTC (rev 321002) +++ php/php-src/branches/PHP_5_4/main/php_variables.c 2011-12-14 08:56:35 UTC (rev 321003) @@ -179,6 +179,9 @@ escaped_index = index; if (zend_symtable_find(symtable1, escaped_index, index_len + 1, (void **) gpc_element_p) == FAILURE || Z_TYPE_PP(gpc_element_p) != IS_ARRAY) { + if (zend_hash_num_elements(symtable1) = PG(max_input_vars)) { + php_error_docref(NULL TSRMLS_CC, E_ERROR, Input variables exceeded %ld. To increase the limit change max_input_vars in php.ini., PG(max_input_vars)); + } MAKE_STD_ZVAL(gpc_element);
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/main/main.c branches/PHP_5_4/main/php_globals.h branches/PHP_5_4/main/php_variables.c trunk/main/main.c trunk/main/php_globals.h
Dmitry, Please update php.ini-*. Thanks, Chris On 12/14/2011 12:56 AM, Dmitry Stogov wrote: dmitry Wed, 14 Dec 2011 08:56:35 + Revision: http://svn.php.net/viewvc?view=revisionrevision=321003 Log: Added max_input_vars directive to prevent attacks based on hash collisions Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/main/main.c U php/php-src/branches/PHP_5_4/main/php_globals.h U php/php-src/branches/PHP_5_4/main/php_variables.c U php/php-src/trunk/main/main.c U php/php-src/trunk/main/php_globals.h U php/php-src/trunk/main/php_variables.c Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-12-14 04:02:56 UTC (rev 321002) +++ php/php-src/branches/PHP_5_4/NEWS 2011-12-14 08:56:35 UTC (rev 321003) @@ -1,6 +1,9 @@ PHP NEWS ||| ?? Dec 2011, PHP 5.4.0 RC4 +- Core: + . Added max_input_vars directive to prevent attacks based on hash collisions +(Dmitry). - CLI SAPI: . Fixed bug #60477 (Segfault after two multipart/form-data POST requests, one 200 RQ and one 404). (Laruence) @@ -9,6 +12,8 @@ 08 Dec 2011, PHP 5.4.0 RC3 - Core: + . Fixed bug #60444 (Segmentation fault with include class extending). +(Laruence, Dmitry). . Fixed bug #60350 (No string escape code for ESC (ascii 27), normally \e). (php at mickweiss dot com) . Fixed bug #60240 (invalid read/writes when unserializing specially crafted Modified: php/php-src/branches/PHP_5_4/main/main.c === --- php/php-src/branches/PHP_5_4/main/main.c2011-12-14 04:02:56 UTC (rev 321002) +++ php/php-src/branches/PHP_5_4/main/main.c2011-12-14 08:56:35 UTC (rev 321003) @@ -531,6 +531,7 @@ STD_PHP_INI_ENTRY(post_max_size,8M, PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateLong, post_max_size, sapi_globals_struct,sapi_globals) STD_PHP_INI_ENTRY(upload_tmp_dir, NULL, PHP_INI_SYSTEM, OnUpdateStringUnempty, upload_tmp_dir, php_core_globals, core_globals) STD_PHP_INI_ENTRY(max_input_nesting_level, 64, PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateLongGEZero, max_input_nesting_level, php_core_globals, core_globals) + STD_PHP_INI_ENTRY(max_input_vars, 1000, PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateLongGEZero, max_input_vars, php_core_globals, core_globals) STD_PHP_INI_ENTRY(user_dir, NULL, PHP_INI_SYSTEM, OnUpdateString, user_dir, php_core_globals, core_globals) STD_PHP_INI_ENTRY(variables_order, EGPCS, PHP_INI_SYSTEM|PHP_INI_PERDIR, OnUpdateStringUnempty, variables_order, php_core_globals, core_globals) Modified: php/php-src/branches/PHP_5_4/main/php_globals.h === --- php/php-src/branches/PHP_5_4/main/php_globals.h 2011-12-14 04:02:56 UTC (rev 321002) +++ php/php-src/branches/PHP_5_4/main/php_globals.h 2011-12-14 08:56:35 UTC (rev 321003) @@ -146,6 +146,7 @@ zend_bool com_initialized; #endif long max_input_nesting_level; + long max_input_vars; zend_bool in_user_include; char *user_ini_filename; Modified: php/php-src/branches/PHP_5_4/main/php_variables.c === --- php/php-src/branches/PHP_5_4/main/php_variables.c 2011-12-14 04:02:56 UTC (rev 321002) +++ php/php-src/branches/PHP_5_4/main/php_variables.c 2011-12-14 08:56:35 UTC (rev 321003) @@ -179,6 +179,9 @@ escaped_index = index; if (zend_symtable_find(symtable1, escaped_index, index_len + 1, (void **)gpc_element_p) == FAILURE || Z_TYPE_PP(gpc_element_p) != IS_ARRAY) { + if (zend_hash_num_elements(symtable1)= PG(max_input_vars)) { + php_error_docref(NULL TSRMLS_CC, E_ERROR, Input variables exceeded %ld. To increase the limit change max_input_vars in php.ini., PG(max_input_vars)); + } MAKE_STD_ZVAL(gpc_element); array_init(gpc_element);
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/main/main.c branches/PHP_5_4/main/php_globals.h branches/PHP_5_4/main/php_ini.c branches/PHP_5_4/tests/basic/bug54514.phpt trunk
this patch is not correct, php crashes on startup when a request is initialized. ==7872==at 0x816204B: php_auto_globals_create_request (php_variables.c:804) ==7872==by 0x818E564: zend_auto_global_init (zend_compile.c:6694) ==7872==by 0x81BB0CE: zend_hash_apply (zend_hash.c:716) ==7872==by 0x818FFEA: zend_activate_auto_globals (zend_compile.c:6704) ==7872==by 0x81629BE: php_hash_environment (php_variables.c:629) ==7872==by 0x8154D1C: php_request_startup (main.c:1567) ==7872==by 0x82507CD: do_cli (php_cli.c:954) ==7872==by 0x8251403: main (php_cli.c:1356) or on windows: php_auto_globals_create_request(const char * name=0x10663298, unsigned int name_len=8, void * * * tsrm_ls=0x026a4f60) Line 804 + 0x16 bytes C zend_auto_global_init(_zend_auto_global * auto_global=0x029a3620, void * * * tsrm_ls=0x026a4f60) Line 6694 + 0x1b bytes C zend_hash_apply(_hashtable * ht=0x029ebd40, int (void *, void * * *)* apply_func=0x1026b880, void * * * tsrm_ls=0x026a4f60) Line 716 + 0x10 bytes C zend_activate_auto_globals(void * * * tsrm_ls=0x026a4f60) Line 6704 + 0x23 bytes C php_hash_environment(void * * * tsrm_ls=0x026a4f60) Line 629 + 0x9 bytes C php_request_startup(void * * * tsrm_ls=0x026a4f60) Line 1567 + 0x9 bytes C do_cli(int argc=6, char * * argv=0x026a4e28, void * * * tsrm_ls=0x026a4f60) Line 954 + 0xc bytes C main(int argc=6, char * * argv=0x026a4e28) Line 1356 + 0x11 bytes C __tmainCRTStartup() Line 586 + 0x19 bytes C mainCRTStartup() Line 403 C On Wed, Dec 7, 2011 at 11:33 AM, Xinchen Hui larue...@php.net wrote: laruence Wed, 07 Dec 2011 10:33:13 + Revision: http://svn.php.net/viewvc?view=revisionrevision=320567 Log: Implemented FR #54514 (Get php binary path during script execution). Bug: https://bugs.php.net/54514 (Open) Get php binary path during script execution Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/main/main.c U php/php-src/branches/PHP_5_4/main/php_globals.h U php/php-src/branches/PHP_5_4/main/php_ini.c A php/php-src/branches/PHP_5_4/tests/basic/bug54514.phpt U php/php-src/trunk/main/main.c U php/php-src/trunk/main/php_globals.h U php/php-src/trunk/main/php_ini.c A php/php-src/trunk/tests/basic/bug54514.phpt -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/main/main.c branches/PHP_5_4/main/php_globals.h branches/PHP_5_4/main/php_ini.c branches/PHP_5_4/tests/basic/bug54514.phpt trunk
seems to be due to partially generated global table, clean build and I cannot reproduce the crash anymore. Sorry for the noise :) On Wed, Dec 7, 2011 at 12:20 PM, Pierre Joye pierre@gmail.com wrote: this patch is not correct, php crashes on startup when a request is initialized. -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/zend_builtin_functions.c branches/PHP_5_4/ext/com_dotnet/com_typeinfo.c branches/PHP_5_4/ext/oci8/oci8.c branches/PHP_5_4/e
Hi Stas 2011/11/18 Stanislav Malyshev s...@php.net: Modified: php/php-src/branches/PHP_5_4/Zend/zend_builtin_functions.c === --- php/php-src/branches/PHP_5_4/Zend/zend_builtin_functions.c 2011-11-18 07:07:42 UTC (rev 319441) +++ php/php-src/branches/PHP_5_4/Zend/zend_builtin_functions.c 2011-11-18 07:11:19 UTC (rev 319442) @@ -706,6 +706,9 @@ } c.flags = case_sensitive; /* non persistent */ c.name = IS_INTERNED(name) ? name : zend_strndup(name, name_len); + if(name == NULL) { + RETURN_FALSE; + } This looks wrong, as c.name have the return value of zend_strndup(), not name. -- regards, Kalle Sommer Nielsen ka...@php.net -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/mbstring/libmbfl/filters/mbfilter_cp936.c branches/PHP_5_4/ext/mbstring/tests/bug60306.phpt trunk/ext/mbstring/libmbfl/filte
Hi Moriyoshi: plz sync this fix into libmbfl :) thanks On Fri, Nov 18, 2011 at 4:50 PM, Xinchen Hui larue...@php.net wrote: laruence Fri, 18 Nov 2011 08:50:29 + Revision: http://svn.php.net/viewvc?view=revisionrevision=319452 Log: Fixed bug #60306 (Characters lost while converting from cp936 to utf8) Bug: https://bugs.php.net/60306 (Assigned) Characters lost while converting from cp936 to utf8 Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/ext/mbstring/libmbfl/filters/mbfilter_cp936.c A php/php-src/branches/PHP_5_4/ext/mbstring/tests/bug60306.phpt U php/php-src/trunk/ext/mbstring/libmbfl/filters/mbfilter_cp936.c A php/php-src/trunk/ext/mbstring/tests/bug60306.phpt Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-11-18 08:30:04 UTC (rev 319451) +++ php/php-src/branches/PHP_5_4/NEWS 2011-11-18 08:50:29 UTC (rev 319452) @@ -35,6 +35,10 @@ . Fixed bug #54682 (Tidy::diagnose() NULL pointer dereference). (Maksymilian Arciemowicz, Felipe) +- Mbstring + . Fixed bug #60306 (Characters lost while converting from cp936 to utf8). + (Laruence) + -CLI SAPI: . Fixed bug #60159 (Router returns false, but POST is not passed to requested resource). (Laruence) Modified: php/php-src/branches/PHP_5_4/ext/mbstring/libmbfl/filters/mbfilter_cp936.c === --- php/php-src/branches/PHP_5_4/ext/mbstring/libmbfl/filters/mbfilter_cp936.c 2011-11-18 08:30:04 UTC (rev 319451) +++ php/php-src/branches/PHP_5_4/ext/mbstring/libmbfl/filters/mbfilter_cp936.c 2011-11-18 08:50:29 UTC (rev 319452) @@ -103,7 +103,7 @@ mbfl_filt_conv_cp936_wchar(int c, mbfl_convert_filter *filter) { int k; - int c1, c2, w; + int c1, c2, w = -1; switch (filter-status) { case 0: @@ -304,5 +304,3 @@ return c; } - - Added: php/php-src/branches/PHP_5_4/ext/mbstring/tests/bug60306.phpt === --- php/php-src/branches/PHP_5_4/ext/mbstring/tests/bug60306.phpt (rev 0) +++ php/php-src/branches/PHP_5_4/ext/mbstring/tests/bug60306.phpt 2011-11-18 08:50:29 UTC (rev 319452) @@ -0,0 +1,11 @@ +--TEST-- +Bug #60306 (Characters lost while converting from cp936 to utf8) +--SKIPIF-- +?php extension_loaded('mbstring') or die('skip mbstring not available'); ? +--FILE-- +?php +$s = 洪仁玕; +var_dump($s === mb_convert_encoding(mb_convert_encoding($s, cp936, utf8), utf8, cp936)); +? +--EXPECT-- +bool(true) Modified: php/php-src/trunk/ext/mbstring/libmbfl/filters/mbfilter_cp936.c === --- php/php-src/trunk/ext/mbstring/libmbfl/filters/mbfilter_cp936.c 2011-11-18 08:30:04 UTC (rev 319451) +++ php/php-src/trunk/ext/mbstring/libmbfl/filters/mbfilter_cp936.c 2011-11-18 08:50:29 UTC (rev 319452) @@ -103,7 +103,7 @@ mbfl_filt_conv_cp936_wchar(int c, mbfl_convert_filter *filter) { int k; - int c1, c2, w; + int c1, c2, w = -1; switch (filter-status) { case 0: @@ -304,5 +304,3 @@ return c; } - - Added: php/php-src/trunk/ext/mbstring/tests/bug60306.phpt === --- php/php-src/trunk/ext/mbstring/tests/bug60306.phpt (rev 0) +++ php/php-src/trunk/ext/mbstring/tests/bug60306.phpt 2011-11-18 08:50:29 UTC (rev 319452) @@ -0,0 +1,11 @@ +--TEST-- +Bug #60306 (Characters lost while converting from cp936 to utf8) +--SKIPIF-- +?php extension_loaded('mbstring') or die('skip mbstring not available'); ? +--FILE-- +?php +$s = 洪仁玕; +var_dump($s === mb_convert_encoding(mb_convert_encoding($s, cp936, utf8), utf8, cp936)); +? +--EXPECT-- +bool(true) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Laruence Xinchen Hui http://www.laruence.com/ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/main/output.c branches/PHP_5_4/tests/output/bug60282.phpt trunk/main/output.c trunk/tests/output/bug60282.phpt
Hi Laruence, ob_gzhandler is only available if php is built --with-zlib This means that your test can fail with Warning: ob_start(): function 'ob_gzhandler' not found or invalid function name on depending on the configure options. Could you please add a SKIPIF and skip the test if ob_gzhandler isn't defined? thanks! On Sun, Nov 13, 2011 at 5:11 AM, Xinchen Hui larue...@php.net wrote: laruence Sun, 13 Nov 2011 04:11:57 + Revision: http://svn.php.net/viewvc?view=revisionrevision=319117 Log: Fixed bug #60282 (Segfault when using ob_gzhandler() with open buffers) Bug: https://bugs.php.net/60282 (Assigned) Segfault when using ob_gzhandler() with open buffers Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/main/output.c A php/php-src/branches/PHP_5_4/tests/output/bug60282.phpt U php/php-src/trunk/main/output.c A php/php-src/trunk/tests/output/bug60282.phpt Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-11-12 23:01:24 UTC (rev 319116) +++ php/php-src/branches/PHP_5_4/NEWS 2011-11-13 04:11:57 UTC (rev 319117) @@ -10,6 +10,10 @@ . Fixed bug #59985 (show normal warning text for OCI_NO_DATA) (Chris Jones) +- Output: + . Fixed bug #60282 (Segfault when using ob_gzhandler() with open buffers). +(Laruence) + 11 Nov 2011, PHP 5.4.0 RC1 - General improvements: . Changed silent conversion of array to string to produce a notice. (Patrick) Modified: php/php-src/branches/PHP_5_4/main/output.c === --- php/php-src/branches/PHP_5_4/main/output.c 2011-11-12 23:01:24 UTC (rev 319116) +++ php/php-src/branches/PHP_5_4/main/output.c 2011-11-13 04:11:57 UTC (rev 319117) @@ -508,14 +508,14 @@ * Check whether a certain output handler is in use */ PHPAPI int php_output_handler_started(const char *name, size_t name_len TSRMLS_DC) { - php_output_handler **handlers; + php_output_handler ***handlers; int i, count = php_output_get_level(TSRMLS_C); if (count) { - handlers = *(php_output_handler ***) zend_stack_base(OG(handlers)); + handlers = (php_output_handler ***) zend_stack_base(OG(handlers)); for (i = 0; i count; ++i) { - if (name_len == handlers[i]-name_len !memcmp(handlers[i]-name, name, name_len)) { + if (name_len == (*(handlers[i]))-name_len !memcmp((*(handlers[i]))-name, name, name_len)) { return 1; } } Added: php/php-src/branches/PHP_5_4/tests/output/bug60282.phpt === --- php/php-src/branches/PHP_5_4/tests/output/bug60282.phpt (rev 0) +++ php/php-src/branches/PHP_5_4/tests/output/bug60282.phpt 2011-11-13 04:11:57 UTC (rev 319117) @@ -0,0 +1,10 @@ +--TEST-- +Bug #60282 (Segfault when using ob_gzhandler() with open buffers) +--FILE-- +?php +ob_start(); +ob_start(); +ob_start('ob_gzhandler'); +echo done; +--EXPECT-- +done Modified: php/php-src/trunk/main/output.c === --- php/php-src/trunk/main/output.c 2011-11-12 23:01:24 UTC (rev 319116) +++ php/php-src/trunk/main/output.c 2011-11-13 04:11:57 UTC (rev 319117) @@ -508,14 +508,14 @@ * Check whether a certain output handler is in use */ PHPAPI int php_output_handler_started(const char *name, size_t name_len TSRMLS_DC) { - php_output_handler **handlers; + php_output_handler ***handlers; int i, count = php_output_get_level(TSRMLS_C); if (count) { - handlers = *(php_output_handler ***) zend_stack_base(OG(handlers)); + handlers = (php_output_handler ***) zend_stack_base(OG(handlers)); for (i = 0; i count; ++i) { - if (name_len == handlers[i]-name_len !memcmp(handlers[i]-name, name, name_len)) { + if (name_len == (*(handlers[i]))-name_len !memcmp((*(handlers[i]))-name, name, name_len)) { return 1; } } Added: php/php-src/trunk/tests/output/bug60282.phpt === --- php/php-src/trunk/tests/output/bug60282.phpt (rev 0) +++ php/php-src/trunk/tests/output/bug60282.phpt2011-11-13 04:11:57 UTC (rev 319117) @@ -0,0 +1,10 @@ +--TEST-- +Bug #60282 (Segfault when using ob_gzhandler() with open buffers) +--FILE-- +?php +ob_start(); +ob_start(); +ob_start('ob_gzhandler'); +echo done; +--EXPECT-- +done -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit:
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/basic_functions.c ext/standard/exec.c ext/standard/exec.h ext/standard/tests/general_functions/bug60116.phpt
On Fri, Nov 11, 2011 at 3:52 PM, Rui Hirokawa hirok...@php.net wrote: hirokawa Fri, 11 Nov 2011 14:52:56 + Revision: http://svn.php.net/viewvc?view=revisionrevision=319057 Log: revert changes to fix bug #60116. Bug: https://bugs.php.net/60116 (Assigned) escapeshellcmd() cannot escape the chars which causes shell injection. Hi. I reopened the ticket as a Documentation Problem, I hope you don't mind. -- Ferenc Kovács @Tyr43l - http://tyrael.hu
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/exec.c ext/standard/tests/general_functions/bug60116.phpt
On Thu, Nov 10, 2011 at 3:19 PM, Rui Hirokawa hirok...@php.net wrote: hirokawa Thu, 10 Nov 2011 14:19:06 + Revision: http://svn.php.net/viewvc?view=revisionrevision=318996 Log: MFH: fixed bug #60116 (escapeshellcmd() cannot escape the characters which cause shell command injection). Bug: https://bugs.php.net/60116 (error getting bug information) Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/ext/standard/exec.c A php/php-src/branches/PHP_5_4/ext/standard/tests/general_functions/bug60116.phpt Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-11-10 14:12:48 UTC (rev 318995) +++ php/php-src/branches/PHP_5_4/NEWS 2011-11-10 14:19:06 UTC (rev 318996) @@ -24,8 +24,10 @@ . Fixed bug #60169 (Conjunction of ternary and list crashes PHP). (Laruence) . Fixed bug #55475 (is_a() triggers autoloader, new optional 3rd argument to -is_a and is_subclass_of). (alan_k) - +is_a and is_subclass_of). (alan_k) + . Fixed bug #60116 (escapeshellcmd() cannot escape the characters + which cause shell command injection). (rui) + - Oracle Database extension (OCI8): . Increased maxium Oracle error message buffer length for new 11.2.0.3 size (Chris Jones) Modified: php/php-src/branches/PHP_5_4/ext/standard/exec.c === --- php/php-src/branches/PHP_5_4/ext/standard/exec.c2011-11-10 14:12:48 UTC (rev 318995) +++ php/php-src/branches/PHP_5_4/ext/standard/exec.c2011-11-10 14:19:06 UTC (rev 318996) @@ -50,6 +50,16 @@ #include unistd.h #endif +/* {{{ register_exec_constants + * */ +void register_exec_constants(INIT_FUNC_ARGS) +{ +REGISTER_LONG_CONSTANT(ESCAPE_CMD_PAIR, ESCAPE_CMD_PAIR, CONST_PERSISTENT|CONST_CS); +REGISTER_LONG_CONSTANT(ESCAPE_CMD_END, ESCAPE_CMD_END, CONST_PERSISTENT|CONST_CS); +REGISTER_LONG_CONSTANT(ESCAPE_CMD_ALL, ESCAPE_CMD_ALL, CONST_PERSISTENT|CONST_CS); +} +/* }}} */ + /* {{{ php_exec * If type==0, only last line of output is returned (exec) * If type==1, all lines will be printed and last lined returned (system) @@ -238,7 +248,7 @@ *NOT* safe for binary strings */ -PHPAPI char *php_escape_shell_cmd(char *str) +PHPAPI char *php_escape_shell_cmd_ex(char *str, int flag) { register int x, y, l = strlen(str); char *cmd; @@ -266,14 +276,26 @@ #ifndef PHP_WIN32 case '': case '\'': - if (!p (p = memchr(str + x + 1, str[x], l - x - 1))) { - /* noop */ - } else if (p *p == str[x]) { - p = NULL; - } else { + if (flag == ESCAPE_CMD_ALL) { cmd[y++] = '\\'; + cmd[y++] = str[x]; + } else if (flag == ESCAPE_CMD_END) { + if ((x == 0 || x == l - 1) (str[0] == str[l-1])) { + cmd[y++] = str[x]; +} else { +cmd[y++] = '\\'; +cmd[y++] = str[x]; +} + } else { /* ESCAPE_CMD_PAIR */ + if (!p (p = memchr(str + x + 1, str[x], l - x - 1))) { + /* noop */ + } else if (p *p == str[x]) { + p = NULL; + } else { + cmd[y++] = '\\'; + } + cmd[y++] = str[x]; } - cmd[y++] = str[x]; break; #else /* % is Windows specific for enviromental variables, ^%PATH% will @@ -327,6 +349,14 @@ } /* }}} */ +/* {{{ php_escape_shell_cmd + */ +PHPAPI char *php_escape_shell_cmd(char *str) +{ +return php_escape_shell_cmd_ex(str, ESCAPE_CMD_PAIR); +} +/* }}} */ + /* {{{ php_escape_shell_arg */ PHPAPI char *php_escape_shell_arg(char *str) @@ -397,14 +427,15 @@ { char *command; int command_len; + long flag = ESCAPE_CMD_PAIR; char *cmd = NULL; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, s, command, command_len) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, s|l, command, command_len, flag) == FAILURE) { return; } if
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS ext/standard/exec.c ext/standard/tests/general_functions/bug60116.phpt
On Thu, Nov 10, 2011 at 15:19, Rui Hirokawa hirok...@php.net wrote: hirokawa Thu, 10 Nov 2011 14:19:06 + Revision: http://svn.php.net/viewvc?view=revisionrevision=318996 Log: MFH: fixed bug #60116 (escapeshellcmd() cannot escape the characters which cause shell command injection). Bug: https://bugs.php.net/60116 (error getting bug information) Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/ext/standard/exec.c A php/php-src/branches/PHP_5_4/ext/standard/tests/general_functions/bug60116.phpt Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-11-10 14:12:48 UTC (rev 318995) +++ php/php-src/branches/PHP_5_4/NEWS 2011-11-10 14:19:06 UTC (rev 318996) @@ -24,8 +24,10 @@ . Fixed bug #60169 (Conjunction of ternary and list crashes PHP). (Laruence) . Fixed bug #55475 (is_a() triggers autoloader, new optional 3rd argument to - is_a and is_subclass_of). (alan_k) - + is_a and is_subclass_of). (alan_k) + . Fixed bug #60116 (escapeshellcmd() cannot escape the characters + which cause shell command injection). (rui) This is the wrong section, rc1 has been release already so this entry belongs at the top of the file, under rc2 -Hannes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/sapi/cli/php_cli_server.c trunk/sapi/cli/php_cli_server.c
Hi: miss update info: Fixed bug #60115 (memory memory definitely lost in cli server) 2011/10/23 Xinchen Hui larue...@php.net: laruence Sun, 23 Oct 2011 03:02:24 + Revision: http://svn.php.net/viewvc?view=revisionrevision=318333 Log: fix memory leak Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/sapi/cli/php_cli_server.c U php/php-src/trunk/sapi/cli/php_cli_server.c Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-10-23 02:54:06 UTC (rev 318332) +++ php/php-src/branches/PHP_5_4/NEWS 2011-10-23 03:02:24 UTC (rev 318333) @@ -3,9 +3,11 @@ ?? ??? 2011, PHP 5.4.0 RC1 - General improvements: . Changed silent conversion of array to string to produce a notice. (Patrick) + - CLI SAPI: . Fixed bug #60112 (If URI does not contain a file, index.php is not served) .(Laruence) + . Fixed bug #60115 (memory definitely lost in cli server). (Laruence) 20 Oct 2011, PHP 5.4.0 beta2 - General improvements: Modified: php/php-src/branches/PHP_5_4/sapi/cli/php_cli_server.c === --- php/php-src/branches/PHP_5_4/sapi/cli/php_cli_server.c 2011-10-23 02:54:06 UTC (rev 318332) +++ php/php-src/branches/PHP_5_4/sapi/cli/php_cli_server.c 2011-10-23 03:02:24 UTC (rev 318333) @@ -1787,6 +1787,9 @@ php_cli_server_log_response(client, status, errstr ? errstr : ? TSRMLS_CC); php_cli_server_poller_add(server-poller, POLLOUT, client-sock); + if (errstr) { + pefree(errstr, 1); + } efree(escaped_request_uri); return SUCCESS; Modified: php/php-src/trunk/sapi/cli/php_cli_server.c === --- php/php-src/trunk/sapi/cli/php_cli_server.c 2011-10-23 02:54:06 UTC (rev 318332) +++ php/php-src/trunk/sapi/cli/php_cli_server.c 2011-10-23 03:02:24 UTC (rev 318333) @@ -1787,6 +1787,9 @@ php_cli_server_log_response(client, status, errstr ? errstr : ? TSRMLS_CC); php_cli_server_poller_add(server-poller, POLLOUT, client-sock); + if (errstr) { + pefree(errstr, 1); + } efree(escaped_request_uri); return SUCCESS; -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Laruence Xinchen Hui http://www.laruence.com/ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/sapi/cli/php_cli_server.c branches/PHP_5_4/sapi/cli/tests/php_cli_server_004.phpt trunk/sapi/cli/php_cli_server.c trunk/sapi/cli
Hello, laruence, could you also take a look here: http://tools.ietf.org/html/draft-robinson-www-interface-00 (see chapter 5. Environment variables) and add them too? Thank you. 2011/9/21 Xinchen Hui larue...@php.net: laruence Wed, 21 Sep 2011 03:09:42 + Revision: http://svn.php.net/viewvc?view=revisionrevision=317074 Log: Fixed bug #55747 (request headers missed in $_SERVER) Bug: https://bugs.php.net/55747 (Open) request headers missed in $_SERVER Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/sapi/cli/php_cli_server.c A php/php-src/branches/PHP_5_4/sapi/cli/tests/php_cli_server_004.phpt U php/php-src/trunk/sapi/cli/php_cli_server.c U php/php-src/trunk/sapi/cli/tests/php_cli_server.inc A php/php-src/trunk/sapi/cli/tests/php_cli_server_004.phpt -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Regards, Shein Alexey -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/session/config.m4 branches/PHP_5_4/ext/session/config.w32 branches/PHP_5_4/ext/session/mod_user.c branches/PHP_5_4/ext/sessi
Hi Arpad 2011/9/14 Arpad Ray ar...@php.net: arpad Tue, 13 Sep 2011 22:28:15 + Revision: http://svn.php.net/viewvc?view=revisionrevision=316688 Log: Implement object-oriented session handlers (https://wiki.php.net/rfc/session-oo) Just by skimming over the patch, then all of those is most likely to fail on Windows because you include the forward slash in the path for error messages, whereas on Windows its a backslash. So you want to use: %stestname.php instead -- regards, Kalle Sommer Nielsen ka...@php.net -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/session/config.m4 branches/PHP_5_4/ext/session/config.w32 branches/PHP_5_4/ext/session/mod_user.c branches/PHP_5_4/ext/sessi
On Wed, Sep 14, 2011 at 1:12 AM, Kalle Sommer Nielsen ka...@php.net wrote: Hi Arpad 2011/9/14 Arpad Ray ar...@php.net: arpad Tue, 13 Sep 2011 22:28:15 + Revision: http://svn.php.net/viewvc?view=revisionrevision=316688 Log: Implement object-oriented session handlers (https://wiki.php.net/rfc/session-oo) Just by skimming over the patch, then all of those is most likely to fail on Windows because you include the forward slash in the path for error messages, whereas on Windows its a backslash. So you want to use: %stestname.php instead Thanks for pointing that out, I've just fixed that test file. :) I haven't been able to test this at all under Windows yet so I'd be very grateful for any further feedback. Regards, Arpad -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/session/config.m4 branches/PHP_5_4/ext/session/config.w32 branches/PHP_5_4/ext/session/mod_user.c branches/PHP_5_4/ext/sessi
On 09/13/2011 06:21 PM, Arpad Ray wrote: On Wed, Sep 14, 2011 at 1:12 AM, Kalle Sommer Nielsenka...@php.net wrote: Hi Arpad 2011/9/14 Arpad Rayar...@php.net: arpadTue, 13 Sep 2011 22:28:15 + Revision: http://svn.php.net/viewvc?view=revisionrevision=316688 Log: Implement object-oriented session handlers (https://wiki.php.net/rfc/session-oo) Just by skimming over the patch, then all of those is most likely to fail on Windows because you include the forward slash in the path for error messages, whereas on Windows its a backslash. So you want to use: %stestname.php instead Thanks for pointing that out, I've just fixed that test file. :) I haven't been able to test this at all under Windows yet so I'd be very grateful for any further feedback. Regards, Arpad Arpad, These are now failing for me on Oracle Linux 5.7, 64 bit: Test session_set_save_handler() : basic class wrapping existing handler [ext/session/tests/session_set_save_handler_class_001.phpt] Test session_set_save_handler() : full handler implementation [ext/session/tests/session_set_save_handler_class_002.phpt] Test session_set_save_handler() : inheritance [ext/session/tests/session_set_save_handler_class_003.phpt] Test session_set_save_handler() : default object [ext/session/tests/session_set_save_handler_class_004.phpt] Test session_set_save_handler() : incomplete implementation [ext/session/tests/session_set_save_handler_class_005.phpt] Test session_set_save_handler() : manual shutdown, reopen [ext/session/tests/session_set_save_handler_class_007.phpt] Test session_set_save_handler() : manual shutdown [ext/session/tests/session_set_save_handler_class_008.phpt] Test session_set_save_handler() : implicit shutdown [ext/session/tests/session_set_save_handler_class_009.phpt] Test session_set_save_handler() : manual shutdown function [ext/session/tests/session_set_save_handler_class_010.phpt] Test session_set_save_handler() : incorrect arguments for existing handler open [ext/session/tests/session_set_save_handler_class_012.phpt] Test session_set_save_handler() : incorrect arguments for existing handler close [ext/session/tests/session_set_save_handler_class_013.phpt] A representative diff shows two kinds of issues: 003+ Read gjtkte0e3upfddc60pkuobqo40 004+ string(26) gjtkte0e3upfddc60pkuobqo40 003- Read %x 004- string(32) %x Chris -- Email: christopher.jo...@oracle.com Tel: +1 650 506 8630 Blog: http://blogs.oracle.com/opal/ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/session/config.m4 branches/PHP_5_4/ext/session/config.w32 branches/PHP_5_4/ext/session/mod_user.c branches/PHP_5_4/ext/sessi
Hi: trunk build broken: ext/session/session.o(.rodata+0x24a8): undefined reference to `zim_SessionHandler_open' ext/session/session.o(.rodata+0x24c8): undefined reference to `zim_SessionHandler_close' ext/session/session.o(.rodata+0x24e8): undefined reference to `zim_SessionHandler_read' ext/session/session.o(.rodata+0x2508): undefined reference to `zim_SessionHandler_write' ext/session/session.o(.rodata+0x2528): undefined reference to `zim_SessionHandler_destroy' ext/session/session.o(.rodata+0x2548): undefined reference to `zim_SessionHandler_gc' collect2: ld returned 1 exit status make: *** [sapi/cli/php] Error 1 make: *** Waiting for unfinished jobs ext/session/session.o(.rodata+0x24a8): undefined reference to `zim_SessionHandler_open' ext/session/session.o(.rodata+0x24c8): undefined reference to `zim_SessionHandler_close' ext/session/session.o(.rodata+0x24e8): undefined reference to `zim_SessionHandler_read' ext/session/session.o(.rodata+0x2508): undefined reference to `zim_SessionHandler_write' ext/session/session.o(.rodata+0x2528): undefined reference to `zim_SessionHandler_destroy' ext/session/session.o(.rodata+0x2548): undefined reference to `zim_SessionHandler_gc' thanks 2011/9/14 Arpad Ray ar...@php.net: arpad Tue, 13 Sep 2011 22:28:15 + Revision: http://svn.php.net/viewvc?view=revisionrevision=316688 Log: Implement object-oriented session handlers (https://wiki.php.net/rfc/session-oo) Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/ext/session/config.m4 U php/php-src/branches/PHP_5_4/ext/session/config.w32 U php/php-src/branches/PHP_5_4/ext/session/mod_user.c A php/php-src/branches/PHP_5_4/ext/session/mod_user_class.c U php/php-src/branches/PHP_5_4/ext/session/package.xml U php/php-src/branches/PHP_5_4/ext/session/php_session.h U php/php-src/branches/PHP_5_4/ext/session/session.c A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_001.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_002.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_003.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_004.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_005.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_006.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_007.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_008.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_009.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_010.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_011.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_012.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_013.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_014.phpt U php/php-src/branches/PHP_5_4/ext/standard/basic_functions.c U php/php-src/branches/PHP_5_4/ext/standard/basic_functions.h U php/php-src/trunk/ext/session/config.m4 U php/php-src/trunk/ext/session/config.w32 U php/php-src/trunk/ext/session/mod_user.c A php/php-src/trunk/ext/session/mod_user_class.c U php/php-src/trunk/ext/session/package.xml U php/php-src/trunk/ext/session/php_session.h U php/php-src/trunk/ext/session/session.c A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_001.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_002.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_003.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_004.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_005.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_006.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_007.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_008.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_009.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_010.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_011.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_012.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_013.phpt A
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/session/config.m4 branches/PHP_5_4/ext/session/config.w32 branches/PHP_5_4/ext/session/mod_user.c branches/PHP_5_4/ext/sessi
Hi: after I re-run buildconf, error has gone sorry for mis-report. thanks 2011/9/14 Laruence larue...@php.net: Hi: trunk build broken: ext/session/session.o(.rodata+0x24a8): undefined reference to `zim_SessionHandler_open' ext/session/session.o(.rodata+0x24c8): undefined reference to `zim_SessionHandler_close' ext/session/session.o(.rodata+0x24e8): undefined reference to `zim_SessionHandler_read' ext/session/session.o(.rodata+0x2508): undefined reference to `zim_SessionHandler_write' ext/session/session.o(.rodata+0x2528): undefined reference to `zim_SessionHandler_destroy' ext/session/session.o(.rodata+0x2548): undefined reference to `zim_SessionHandler_gc' collect2: ld returned 1 exit status make: *** [sapi/cli/php] Error 1 make: *** Waiting for unfinished jobs ext/session/session.o(.rodata+0x24a8): undefined reference to `zim_SessionHandler_open' ext/session/session.o(.rodata+0x24c8): undefined reference to `zim_SessionHandler_close' ext/session/session.o(.rodata+0x24e8): undefined reference to `zim_SessionHandler_read' ext/session/session.o(.rodata+0x2508): undefined reference to `zim_SessionHandler_write' ext/session/session.o(.rodata+0x2528): undefined reference to `zim_SessionHandler_destroy' ext/session/session.o(.rodata+0x2548): undefined reference to `zim_SessionHandler_gc' thanks 2011/9/14 Arpad Ray ar...@php.net: arpad Tue, 13 Sep 2011 22:28:15 + Revision: http://svn.php.net/viewvc?view=revisionrevision=316688 Log: Implement object-oriented session handlers (https://wiki.php.net/rfc/session-oo) Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/ext/session/config.m4 U php/php-src/branches/PHP_5_4/ext/session/config.w32 U php/php-src/branches/PHP_5_4/ext/session/mod_user.c A php/php-src/branches/PHP_5_4/ext/session/mod_user_class.c U php/php-src/branches/PHP_5_4/ext/session/package.xml U php/php-src/branches/PHP_5_4/ext/session/php_session.h U php/php-src/branches/PHP_5_4/ext/session/session.c A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_001.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_002.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_003.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_004.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_005.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_006.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_007.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_008.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_009.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_010.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_011.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_012.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_013.phpt A php/php-src/branches/PHP_5_4/ext/session/tests/session_set_save_handler_class_014.phpt U php/php-src/branches/PHP_5_4/ext/standard/basic_functions.c U php/php-src/branches/PHP_5_4/ext/standard/basic_functions.h U php/php-src/trunk/ext/session/config.m4 U php/php-src/trunk/ext/session/config.w32 U php/php-src/trunk/ext/session/mod_user.c A php/php-src/trunk/ext/session/mod_user_class.c U php/php-src/trunk/ext/session/package.xml U php/php-src/trunk/ext/session/php_session.h U php/php-src/trunk/ext/session/session.c A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_001.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_002.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_003.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_004.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_005.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_006.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_007.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_008.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_009.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_010.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_011.phpt A php/php-src/trunk/ext/session/tests/session_set_save_handler_class_012.phpt A
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/tests/closure_036.phpt branches/PHP_5_4/Zend/tests/closure_038.phpt branches/PHP_5_4/Zend/tests/closure_039.phpt branches/P
On Wed, Sep 7, 2011 at 08:46, Stanislav Malyshev s...@php.net wrote: stas Wed, 07 Sep 2011 06:46:27 + Revision: http://svn.php.net/viewvc?view=revisionrevision=316300 Log: Commit Gustavo's closure rebinding patch as desided by vote Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/Zend/tests/closure_036.phpt Modified: php/php-src/branches/PHP_5_4/Zend/tests/closure_036.phpt === --- php/php-src/branches/PHP_5_4/Zend/tests/closure_036.phpt2011-09-07 05:19:12 UTC (rev 316299) +++ php/php-src/branches/PHP_5_4/Zend/tests/closure_036.phpt2011-09-07 06:46:27 UTC (rev 316300) @@ -1,5 +1,5 @@ --TEST-- -Closure 036: Rebinding closures +Closure 036: Rebinding closures, keep calling scope --FILE-- ?php @@ -20,7 +20,7 @@ $ca = $a-getIncrementor(); $cb = $ca-bindTo($b); -$cb2 = Closure::bind($b, $ca); +$cb2 = Closure::bind($ca, $b); That change seems a bit weird to me and quite big BC break. Please update the migration file with details on this. -Hannes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS
- Removed features: - . Removed magic_quotes_gpc, magic_quotes_runtime and magic_quotes_sybase ini options. - get_magic_quotes_gpc, get_magic_quotes_runtime are kept but always return - false, set_magic_quotes_runtime raises an E_CORE_ERROR. (Pierrick, Pierre) + . Removed magic_quotes_gpc, magic_quotes_runtime and magic_quotes_sybase + ini options. get_magic_quotes_gpc, get_magic_quotes_runtime are kept + but always return false, set_magic_quotes_runtime raises an + E_CORE_ERROR. (Pierrick, Pierre) maybe we should mention, that trying to enable magic_quotes through the ini files (or the -d for the cli) will also generate a fatal error AFAIR. -- Ferenc Kovács @Tyr43l - http://tyrael.hu -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/tests/closure_036.phpt branches/PHP_5_4/Zend/tests/closure_038.phpt branches/PHP_5_4/Zend/tests/closure_039.phpt branches/P
On Wed, 07 Sep 2011 10:38:54 +0100, Hannes Magnusson hannes.magnus...@gmail.com wrote: On Wed, Sep 7, 2011 at 08:46, Stanislav Malyshev s...@php.net wrote: stas Wed, 07 Sep 2011 06:46:27 + Revision: http://svn.php.net/viewvc?view=revisionrevision=316300 [...] @@ -20,7 +20,7 @@ $ca = $a-getIncrementor(); $cb = $ca-bindTo($b); -$cb2 = Closure::bind($b, $ca); +$cb2 = Closure::bind($ca, $b); That change seems a bit weird to me and quite big BC break. Please update the migration file with details on this. There's no BC break as this function is new in 5.4. Unless you mean BC break from the latest alpha. -- Gustavo Lopes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/tests/closure_036.phpt branches/PHP_5_4/Zend/tests/closure_038.phpt branches/PHP_5_4/Zend/tests/closure_039.phpt branches/P
On Wed, Sep 7, 2011 at 16:00, Gustavo A. S. Lopes glo...@nebm.ist.utl.pt wrote: On Wed, 07 Sep 2011 10:38:54 +0100, Hannes Magnusson hannes.magnus...@gmail.com wrote: On Wed, Sep 7, 2011 at 08:46, Stanislav Malyshev s...@php.net wrote: stas Wed, 07 Sep 2011 06:46:27 + Revision: http://svn.php.net/viewvc?view=revisionrevision=316300 [...] @@ -20,7 +20,7 @@ $ca = $a-getIncrementor(); $cb = $ca-bindTo($b); -$cb2 = Closure::bind($b, $ca); +$cb2 = Closure::bind($ca, $b); That change seems a bit weird to me and quite big BC break. Please update the migration file with details on this. There's no BC break as this function is new in 5.4. Unless you mean BC break from the latest alpha. Ahh. Explains why I had a hard time finding anything related in the docs :) -Hannes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/standard/string.c branches/PHP_5_4/ext/standard/tests/strings/substr_replace_array.phpt trunk/ext/standard/string.c trunk/ex
On Mon, Aug 29, 2011 at 22:38, Arpad Ray ar...@php.net wrote: arpad Mon, 29 Aug 2011 20:38:52 + Revision: http://svn.php.net/viewvc?view=revisionrevision=315740 Log: Fixed bug #55366: keys lost when using substr_replace an array Bug: https://bugs.php.net/55366 (Open) keys lost when using substr_replace replace an array Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/ext/standard/string.c A php/php-src/branches/PHP_5_4/ext/standard/tests/strings/substr_replace_array.phpt U php/php-src/trunk/ext/standard/string.c A php/php-src/trunk/ext/standard/tests/strings/substr_replace_array.phpt Not to 5.3? -Hannes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/sapi/cli/php_cli_server.c trunk/NEWS trunk/sapi/cli/php_cli_server.c
Hi 2011/8/22 Xinchen Hui larue...@php.net: laruence Mon, 22 Aug 2011 11:55:41 + Revision: http://svn.php.net/viewvc?view=revisionrevision=315278 Log: Fixed #55463 (cli-server missing _SERVER[REMOTE_ADDR]) We might as well add SERVER_ADDR (+ SERVER_SOFTWARE) if not available too -- regards, Kalle Sommer Nielsen ka...@php.net -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/sapi/cli/php_cli_server.c trunk/NEWS trunk/sapi/cli/php_cli_server.c
open a new FR please. Easier than following php-cvs for new FR. On Mon, Aug 22, 2011 at 2:17 PM, Kalle Sommer Nielsen ka...@php.net wrote: Hi 2011/8/22 Xinchen Hui larue...@php.net: laruence Mon, 22 Aug 2011 11:55:41 + Revision: http://svn.php.net/viewvc?view=revisionrevision=315278 Log: Fixed #55463 (cli-server missing _SERVER[REMOTE_ADDR]) We might as well add SERVER_ADDR (+ SERVER_SOFTWARE) if not available too -- regards, Kalle Sommer Nielsen ka...@php.net -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/sapi/cli/php_cli_server.c trunk/NEWS trunk/sapi/cli/php_cli_server.c
Hi: Added SERVER[SERVER_SOFTWARE], http://svn.php.net/viewvc?view=revisionrevision=315300 but server_addr is a litte diffcult since there is no a ready value for that, needs a litte more works, I think we'd better not do that much changes for this, at least need the author to review, :) thanks 2011/8/22 Pierre Joye pierre@gmail.com: open a new FR please. Easier than following php-cvs for new FR. On Mon, Aug 22, 2011 at 2:17 PM, Kalle Sommer Nielsen ka...@php.net wrote: Hi 2011/8/22 Xinchen Hui larue...@php.net: laruence Mon, 22 Aug 2011 11:55:41 + Revision: http://svn.php.net/viewvc?view=revisionrevision=315278 Log: Fixed #55463 (cli-server missing _SERVER[REMOTE_ADDR]) We might as well add SERVER_ADDR (+ SERVER_SOFTWARE) if not available too -- regards, Kalle Sommer Nielsen ka...@php.net -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- Laruence Xinchen Hui http://www.laruence.com/ -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/zend_builtin_functions.c branches/PHP_5_4/Zend/zend_errors.h branches/PHP_5_4/php.ini-development branches/PHP_5_4/php.ini-
Hi: On Sun, Jul 24, 2011 at 12:07 AM, Stanislav Malyshev s...@php.net wrote: stas Sat, 23 Jul 2011 22:07:22 + Revision: http://svn.php.net/viewvc?view=revisionrevision=313645 Log: Change E_ALL to include E_STRICT Could please someone take the time to fix the tests which are related to that. I won't get to it today, sorry, but for instance Zend/tests/error_reporting* look like they need some adaptation. Thanks Stefan -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/Zend/zend_builtin_functions.c branches/PHP_5_4/Zend/zend_errors.h branches/PHP_5_4/php.ini-development branches/PHP_5_4/php.ini-
2011/7/31 Stefan Marr p...@stefan-marr.de: Hi: On Sun, Jul 24, 2011 at 12:07 AM, Stanislav Malyshev s...@php.net wrote: stas Sat, 23 Jul 2011 22:07:22 + Revision: http://svn.php.net/viewvc?view=revisionrevision=313645 Log: Change E_ALL to include E_STRICT Could please someone take the time to fix the tests which are related to that. I won't get to it today, sorry, but for instance Zend/tests/error_reporting* look like they need some adaptation. Done. -- Regards, Felipe Pena -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS
how so? On Wed, Jul 13, 2011 at 10:12 PM, Stanislav Malyshev s...@php.net wrote: stas Wed, 13 Jul 2011 20:12:14 + Revision: http://svn.php.net/viewvc?view=revisionrevision=313214 Log: integrate 5.3 NEWS Changed paths: U php/php-src/branches/PHP_5_4/NEWS Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-07-13 19:41:13 UTC (rev 313213) +++ php/php-src/branches/PHP_5_4/NEWS 2011-07-13 20:12:14 UTC (rev 313214) @@ -266,6 +266,59 @@ - Fixed PDO objects binary incompatibility. (Dmitry) - Fixed bug #52211 (iconv() returns part of string on error). (Felipe) +?? ??? 2011, PHP 5.3.7 +- Zend Engine: + . Fixed bug #55156 (ReflectionClass::getDocComment() returns comment even + though the class has none). (Felipe) + +- Core + . Fixed bug #55014 (Compile failure due to improper use of ctime_r()). (Ilia) + . Fixed bug #54332 (Crash in zend_mm_check_ptr // Heap corruption). (Dmitry) + . Fixed bug #54305 (Crash in gc_remove_zval_from_buffer). (Dmitry) + . Fixed bug #53727 (Inconsistent behavior of is_subclass_of with interfaces) + (Ralph Schindler, Dmitry) + . Fixed buffer overflow on overlog salt in crypt(). (Clément LECIGNE, Stas) + . Fixed bug #52935 (call exit in user_error_handler cause stream relate + core). (Gustavo) + +- MCrypt + . Change E_ERROR to E_WARNING in mcrypt_create_iv when not enough data + has been fetched (Windows). (Pierre) + . Fixed bug #55169 (mcrypt_create_iv always fails to gather sufficient random + data on Windows). (Pierre) + +- PDO DBlib: + . Fixed bug #54329 (MSSql extension memory leak). + (dotslashpok at gmail dot com) + +30 Jun 2011, PHP 5.3.7 RC2 +- Core: + . Fixed crash in error_log(). (Felipe) Reported by Mateusz Kocielski. + . Fixed bug #55082 (var_export() doesn't escape properties properly). + (Gustavo) + +- DateTime extension: + . Fixed bug where the DateTime object got changed while using date_diff(). + (Derick) + +- DBA extension: + . Supress warning on non-existent file open with Berkeley DB 5.2 (Chris Jones) + +- PDO ODBC driver: + . Fixed data type usage in 64bit. (leocsilva at gmail dot com) + +- PHP-FPM SAPI: + . Implemented FR #54499 (FPM ping and status_path should handle HEAD request). (fat) + . Implemented FR #54172 (Overriding the pid file location of php-fpm). (fat) + . Fixed missing Expires and Cache-Control headers for ping and status pages. + (fat) + . Fixed memory leak. (fat) Reported and fixed by Giovanni Giacobbi. + . Fixed wrong value of log_level when invoking fpm with -tt. (fat) + +- SPL extension: + . Fixed bug #54971 (Wrong result when using iterator_to_array with use_keys + on true). (Pierrick) + 16 Jun 2011, PHP 5.3.7 RC1 - Upgraded bundled SQLite to version 3.7.6.3. (Scott) - Upgraded bundled PCRE to version 8.12. (Scott) @@ -429,7 +482,18 @@ - Phar extension: . Fixed bug #54395 (Phar::mount() crashes when calling with wrong parameters). (Felipe) - + +- PHP-FPM SAPI: + . Added xml format to the status page. (fat) + . Removed timestamp in logs written by children processes. (fat) + . Fixed exit at FPM startup on fpm_resources_prepare() errors. (fat) + . Added master rlimit_files and rlimit_core in the global configuration + settings. (fat) + . Removed pid in debug logs written by chrildren processes. (fat) + . Added custom access log (also added per request %CPU and memory + mesurement). (fat) + . Added a real scoreboard and several improvements to the status page. (fat) + - Reflection extension: . Fixed bug #54347 (reflection_extension does not lowercase module function name). (Felipe, laruence at yahoo dot com dot cn) -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/standard/basic_functions.c branches/PHP_5_4/ext/standard/head.c trunk/ext/standard/basic_functions.c trunk/ext/standard/head
Hi! On 7/11/11 8:56 PM, Kalle Sommer Nielsen wrote: kalleTue, 12 Jul 2011 03:56:32 + Revision: http://svn.php.net/viewvc?view=revisionrevision=313156 Log: Changed http_response_code() to be able to set a response code Are you sure this patch is right and you shouldn't use header_op instead? What happens to http_status_line? headers_op does it differently at least. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS configure.in main/php_version.h
On Sun, Jun 19, 2011 at 22:15, Stanislav Malyshev s...@php.net wrote: stas Sun, 19 Jun 2011 20:15:33 + Revision: http://svn.php.net/viewvc?view=revisionrevision=312302 Log: Back to -dev Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/configure.in U php/php-src/branches/PHP_5_4/main/php_version.h Modified: php/php-src/branches/PHP_5_4/NEWS === --- php/php-src/branches/PHP_5_4/NEWS 2011-06-19 20:13:45 UTC (rev 312301) +++ php/php-src/branches/PHP_5_4/NEWS 2011-06-19 20:15:33 UTC (rev 312302) @@ -1,6 +1,6 @@ PHP NEWS ||| -20 Jun 2011, PHP 5.4.0 Alpha 1 +?? ??? 2011, PHP 5.4.0 Hmmmh.. So the news for alpha2 will not be separated from alpha1? Thats going to make it hard to see the difference for users :] -Hannes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS configure.in main/php_version.h
Hi! On 7/6/11 12:12 PM, Hannes Magnusson wrote: Hmmmh.. So the news for alpha2 will not be separated from alpha1? Thats going to make it hard to see the difference for users :] Well, alphas aren't really for users - i.e., it should not be used in any setting where the difference (as opposed to whole product working/not working) is important. Also, we don't have non-release versions in any other parts of the NEWS. Do you think we should have it in 5.4? It would then be required to merge it when we release a stable version, I guess? -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS configure.in main/php_version.h
On 07/06/2011 12:18 PM, Stas Malyshev wrote: Hi! On 7/6/11 12:12 PM, Hannes Magnusson wrote: Hmmmh.. So the news for alpha2 will not be separated from alpha1? Thats going to make it hard to see the difference for users :] Well, alphas aren't really for users - i.e., it should not be used in any setting where the difference (as opposed to whole product working/not working) is important. Also, we don't have non-release versions in any other parts of the NEWS. Do you think we should have it in 5.4? It would then be required to merge it when we release a stable version, I guess? Given the pretty big changes that are likely to occur between alpha releases, I think it would be a good idea to have separated NEWS sections. And yes, when we put out the first beta we merge them all. -Rasmus -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS configure.in main/php_version.h
Hi! On 7/6/11 12:20 PM, Rasmus Lerdorf wrote: Given the pretty big changes that are likely to occur between alpha releases, I think it would be a good idea to have separated NEWS sections. And yes, when we put out the first beta we merge them all. OK, I'll split them. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS configure.in main/php_version.h
On Wed, Jul 6, 2011 at 9:20 PM, Rasmus Lerdorf ras...@lerdorf.com wrote: Given the pretty big changes that are likely to occur between alpha releases, I think it would be a good idea to have separated NEWS sections. And yes, when we put out the first beta we merge them all. Exactly, every change happening between two tests releases (no matter the state) has its NEWS entry. They got merged, removed or rephrased for the final release. Cheers. -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS TSRM/TSRM.c TSRM/TSRM.h TSRM/tsrm.m4 Zend/Makefile.am Zend/Zend.m4 Zend/zend.c Zend/zend.h Zend/zend_alloc.c Zend/zend_execute_API.c Zend/zend_ha
Le 23 juin 2011 02:41, Felipe Pena felipe...@gmail.com a écrit : Try again, please. :) yeah it works ! thanks you very much for your time ++ jerome -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS TSRM/TSRM.c TSRM/TSRM.h TSRM/tsrm.m4 Zend/Makefile.am Zend/Zend.m4 Zend/zend.c Zend/zend.h Zend/zend_alloc.c Zend/zend_execute_API.c Zend/zend_ha
Hi it breaks FPM in 5.4 branch on my server: fat@dev:~/dev/php-src/branches/PHP_5_4$ gdb ./sapi/fpm/php-fpm GNU gdb (Ubuntu/Linaro 7.2-1ubuntu11) 7.2 Copyright (C) 2010 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 x86_64-linux-gnu. For bug reporting instructions, please see: http://www.gnu.org/software/gdb/bugs/... Reading symbols from /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm...done. (gdb) run Starting program: /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm [Thread debugging using libthread_db enabled] Program received signal SIGSEGV, Segmentation fault. 0x76ec8394 in pthread_mutex_lock () from /lib/x86_64-linux-gnu/libpthread.so.0 (gdb) bt #0 0x76ec8394 in pthread_mutex_lock () from /lib/x86_64-linux-gnu/libpthread.so.0 #1 0x005dc336 in tsrm_mutex_lock (mutexp=0x0) at /home/fat/dev/php-src/branches/PHP_5_4/TSRM/TSRM.c:666 #2 0x005dbaff in ts_resource_ex (id=0, th_id=0x0) at /home/fat/dev/php-src/branches/PHP_5_4/TSRM/TSRM.c:345 #3 0x0065858a in zend_strndup (s=0x98ec46 0, length=1) at /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_alloc.c:2612 #4 0x0080f290 in fcgi_set_mgmt_var (name=0x98ec48 FCGI_MPXS_CONNS, name_len=15, value=0x98ec46 0, value_len=1) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:1109 #5 0x0080cf9f in fcgi_init () at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:195 #6 0x00818e16 in main (argc=1, argv=0x7fffe158) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fpm_main.c:1590 fat@dev:~/dev/php-src/branches/PHP_5_4$ cat config.nice #! /bin/sh # # Created by configure './configure' \ '--disable-all' \ '--enable-fpm' \ '--prefix=/home/fat/php/5.4.x' \ '--enable-session' \ '--enable-phar' \ '--enable-debug' \ '--enable-maintainer-zts' \ $@ the code arround line 1109 in sapi/fpm/fpm/fastcgi.c void fcgi_set_mgmt_var(const char * name, size_t name_len, const char * value, size_t value_len) { zval * zvalue; zvalue = pemalloc(sizeof(*zvalue), 1); Z_TYPE_P(zvalue) = IS_STRING; Z_STRVAL_P(zvalue) = pestrndup(value, value_len, 1); /* -- this line */ Z_STRLEN_P(zvalue) = value_len; zend_hash_add(fcgi_mgmt_vars, name, name_len + 1, zvalue, sizeof(zvalue), NULL); } is there something to change in the call to pestrndup ? ++ Jerome 2011/6/22 Ilia Alshanetsky il...@php.net: iliaa Wed, 22 Jun 2011 14:23:21 + Revision: http://svn.php.net/viewvc?view=revisionrevision=312377 Log: Zend Signal Handling Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/TSRM/TSRM.c U php/php-src/branches/PHP_5_4/TSRM/TSRM.h U php/php-src/branches/PHP_5_4/TSRM/tsrm.m4 U php/php-src/branches/PHP_5_4/Zend/Makefile.am U php/php-src/branches/PHP_5_4/Zend/Zend.m4 U php/php-src/branches/PHP_5_4/Zend/zend.c U php/php-src/branches/PHP_5_4/Zend/zend.h U php/php-src/branches/PHP_5_4/Zend/zend_alloc.c U php/php-src/branches/PHP_5_4/Zend/zend_execute_API.c U php/php-src/branches/PHP_5_4/Zend/zend_hash.c A php/php-src/branches/PHP_5_4/Zend/zend_signal.c A php/php-src/branches/PHP_5_4/Zend/zend_signal.h U php/php-src/branches/PHP_5_4/configure.in U php/php-src/branches/PHP_5_4/ext/pcntl/pcntl.c U php/php-src/branches/PHP_5_4/ext/pcntl/php_signal.c U php/php-src/branches/PHP_5_4/ext/pcntl/tests/pcntl_signal.phpt U php/php-src/branches/PHP_5_4/ext/standard/info.c U php/php-src/branches/PHP_5_4/ext/standard/tests/file/bug22414.phpt U php/php-src/branches/PHP_5_4/ext/standard/tests/general_functions/phpinfo.phpt U php/php-src/branches/PHP_5_4/main/SAPI.c U php/php-src/branches/PHP_5_4/main/main.c -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS TSRM/TSRM.c TSRM/TSRM.h TSRM/tsrm.m4 Zend/Makefile.am Zend/Zend.m4 Zend/zend.c Zend/zend.h Zend/zend_alloc.c Zend/zend_execute_API.c Zend/zend_ha
Hi, I've committed a fix, can you check if it's ok? 2011/6/22 Jérôme Loyet m...@fatbsd.com: Hi it breaks FPM in 5.4 branch on my server: fat@dev:~/dev/php-src/branches/PHP_5_4$ gdb ./sapi/fpm/php-fpm GNU gdb (Ubuntu/Linaro 7.2-1ubuntu11) 7.2 Copyright (C) 2010 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 x86_64-linux-gnu. For bug reporting instructions, please see: http://www.gnu.org/software/gdb/bugs/... Reading symbols from /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm...done. (gdb) run Starting program: /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm [Thread debugging using libthread_db enabled] Program received signal SIGSEGV, Segmentation fault. 0x76ec8394 in pthread_mutex_lock () from /lib/x86_64-linux-gnu/libpthread.so.0 (gdb) bt #0 0x76ec8394 in pthread_mutex_lock () from /lib/x86_64-linux-gnu/libpthread.so.0 #1 0x005dc336 in tsrm_mutex_lock (mutexp=0x0) at /home/fat/dev/php-src/branches/PHP_5_4/TSRM/TSRM.c:666 #2 0x005dbaff in ts_resource_ex (id=0, th_id=0x0) at /home/fat/dev/php-src/branches/PHP_5_4/TSRM/TSRM.c:345 #3 0x0065858a in zend_strndup (s=0x98ec46 0, length=1) at /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_alloc.c:2612 #4 0x0080f290 in fcgi_set_mgmt_var (name=0x98ec48 FCGI_MPXS_CONNS, name_len=15, value=0x98ec46 0, value_len=1) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:1109 #5 0x0080cf9f in fcgi_init () at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:195 #6 0x00818e16 in main (argc=1, argv=0x7fffe158) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fpm_main.c:1590 fat@dev:~/dev/php-src/branches/PHP_5_4$ cat config.nice #! /bin/sh # # Created by configure './configure' \ '--disable-all' \ '--enable-fpm' \ '--prefix=/home/fat/php/5.4.x' \ '--enable-session' \ '--enable-phar' \ '--enable-debug' \ '--enable-maintainer-zts' \ $@ the code arround line 1109 in sapi/fpm/fpm/fastcgi.c void fcgi_set_mgmt_var(const char * name, size_t name_len, const char * value, size_t value_len) { zval * zvalue; zvalue = pemalloc(sizeof(*zvalue), 1); Z_TYPE_P(zvalue) = IS_STRING; Z_STRVAL_P(zvalue) = pestrndup(value, value_len, 1); /* -- this line */ Z_STRLEN_P(zvalue) = value_len; zend_hash_add(fcgi_mgmt_vars, name, name_len + 1, zvalue, sizeof(zvalue), NULL); } is there something to change in the call to pestrndup ? ++ Jerome 2011/6/22 Ilia Alshanetsky il...@php.net: iliaa Wed, 22 Jun 2011 14:23:21 + Revision: http://svn.php.net/viewvc?view=revisionrevision=312377 Log: Zend Signal Handling Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/TSRM/TSRM.c U php/php-src/branches/PHP_5_4/TSRM/TSRM.h U php/php-src/branches/PHP_5_4/TSRM/tsrm.m4 U php/php-src/branches/PHP_5_4/Zend/Makefile.am U php/php-src/branches/PHP_5_4/Zend/Zend.m4 U php/php-src/branches/PHP_5_4/Zend/zend.c U php/php-src/branches/PHP_5_4/Zend/zend.h U php/php-src/branches/PHP_5_4/Zend/zend_alloc.c U php/php-src/branches/PHP_5_4/Zend/zend_execute_API.c U php/php-src/branches/PHP_5_4/Zend/zend_hash.c A php/php-src/branches/PHP_5_4/Zend/zend_signal.c A php/php-src/branches/PHP_5_4/Zend/zend_signal.h U php/php-src/branches/PHP_5_4/configure.in U php/php-src/branches/PHP_5_4/ext/pcntl/pcntl.c U php/php-src/branches/PHP_5_4/ext/pcntl/php_signal.c U php/php-src/branches/PHP_5_4/ext/pcntl/tests/pcntl_signal.phpt U php/php-src/branches/PHP_5_4/ext/standard/info.c U php/php-src/branches/PHP_5_4/ext/standard/tests/file/bug22414.phpt U php/php-src/branches/PHP_5_4/ext/standard/tests/general_functions/phpinfo.phpt U php/php-src/branches/PHP_5_4/main/SAPI.c U php/php-src/branches/PHP_5_4/main/main.c -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Regards, Felipe Pena -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS TSRM/TSRM.c TSRM/TSRM.h TSRM/tsrm.m4 Zend/Makefile.am Zend/Zend.m4 Zend/zend.c Zend/zend.h Zend/zend_alloc.c Zend/zend_execute_API.c Zend/zend_ha
Le 23 juin 2011 02:26, Felipe Pena felipe...@gmail.com a écrit : Hi, I've committed a fix, can you check if it's ok? nope: fat@dev:~/dev/php-src/branches/PHP_5_4$ gdb ./sapi/fpm/php-fpm GNU gdb (Ubuntu/Linaro 7.2-1ubuntu11) 7.2 Copyright (C) 2010 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 x86_64-linux-gnu. For bug reporting instructions, please see: http://www.gnu.org/software/gdb/bugs/... Reading symbols from /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm...done. (gdb) r Starting program: /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm [Thread debugging using libthread_db enabled] Program received signal SIGSEGV, Segmentation fault. 0x0065868c in zend_strndup (s=0x990946 0, length=1) at /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_alloc.c:2615 2615HANDLE_BLOCK_INTERRUPTIONS(); (gdb) bt #0 0x0065868c in zend_strndup (s=0x990946 0, length=1) at /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_alloc.c:2615 #1 0x0080f418 in fcgi_set_mgmt_var (name=0x990948 FCGI_MPXS_CONNS, name_len=15, value=0x990946 0, value_len=1) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:1113 #2 0x0080d07f in fcgi_init () at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:197 #3 0x0081a93c in main (argc=1, argv=0x7fffe158) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fpm_main.c:1607 2011/6/22 Jérôme Loyet m...@fatbsd.com: Hi it breaks FPM in 5.4 branch on my server: fat@dev:~/dev/php-src/branches/PHP_5_4$ gdb ./sapi/fpm/php-fpm GNU gdb (Ubuntu/Linaro 7.2-1ubuntu11) 7.2 Copyright (C) 2010 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 x86_64-linux-gnu. For bug reporting instructions, please see: http://www.gnu.org/software/gdb/bugs/... Reading symbols from /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm...done. (gdb) run Starting program: /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm [Thread debugging using libthread_db enabled] Program received signal SIGSEGV, Segmentation fault. 0x76ec8394 in pthread_mutex_lock () from /lib/x86_64-linux-gnu/libpthread.so.0 (gdb) bt #0 0x76ec8394 in pthread_mutex_lock () from /lib/x86_64-linux-gnu/libpthread.so.0 #1 0x005dc336 in tsrm_mutex_lock (mutexp=0x0) at /home/fat/dev/php-src/branches/PHP_5_4/TSRM/TSRM.c:666 #2 0x005dbaff in ts_resource_ex (id=0, th_id=0x0) at /home/fat/dev/php-src/branches/PHP_5_4/TSRM/TSRM.c:345 #3 0x0065858a in zend_strndup (s=0x98ec46 0, length=1) at /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_alloc.c:2612 #4 0x0080f290 in fcgi_set_mgmt_var (name=0x98ec48 FCGI_MPXS_CONNS, name_len=15, value=0x98ec46 0, value_len=1) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:1109 #5 0x0080cf9f in fcgi_init () at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:195 #6 0x00818e16 in main (argc=1, argv=0x7fffe158) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fpm_main.c:1590 fat@dev:~/dev/php-src/branches/PHP_5_4$ cat config.nice #! /bin/sh # # Created by configure './configure' \ '--disable-all' \ '--enable-fpm' \ '--prefix=/home/fat/php/5.4.x' \ '--enable-session' \ '--enable-phar' \ '--enable-debug' \ '--enable-maintainer-zts' \ $@ the code arround line 1109 in sapi/fpm/fpm/fastcgi.c void fcgi_set_mgmt_var(const char * name, size_t name_len, const char * value, size_t value_len) { zval * zvalue; zvalue = pemalloc(sizeof(*zvalue), 1); Z_TYPE_P(zvalue) = IS_STRING; Z_STRVAL_P(zvalue) = pestrndup(value, value_len, 1); /* -- this line */ Z_STRLEN_P(zvalue) = value_len; zend_hash_add(fcgi_mgmt_vars, name, name_len + 1, zvalue, sizeof(zvalue), NULL); } is there something to change in the call to pestrndup ? ++ Jerome 2011/6/22 Ilia Alshanetsky il...@php.net: iliaa Wed, 22 Jun 2011 14:23:21 + Revision: http://svn.php.net/viewvc?view=revisionrevision=312377 Log: Zend Signal Handling Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/TSRM/TSRM.c U php/php-src/branches/PHP_5_4/TSRM/TSRM.h U php/php-src/branches/PHP_5_4/TSRM/tsrm.m4 U php/php-src/branches/PHP_5_4/Zend/Makefile.am U php/php-src/branches/PHP_5_4/Zend/Zend.m4 U php/php-src/branches/PHP_5_4/Zend/zend.c U php/php-src/branches/PHP_5_4/Zend/zend.h
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS TSRM/TSRM.c TSRM/TSRM.h TSRM/tsrm.m4 Zend/Makefile.am Zend/Zend.m4 Zend/zend.c Zend/zend.h Zend/zend_alloc.c Zend/zend_execute_API.c Zend/zend_ha
Try again, please. :) 2011/6/22 Jérôme Loyet m...@fatbsd.com: Le 23 juin 2011 02:26, Felipe Pena felipe...@gmail.com a écrit : Hi, I've committed a fix, can you check if it's ok? nope: fat@dev:~/dev/php-src/branches/PHP_5_4$ gdb ./sapi/fpm/php-fpm GNU gdb (Ubuntu/Linaro 7.2-1ubuntu11) 7.2 Copyright (C) 2010 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 x86_64-linux-gnu. For bug reporting instructions, please see: http://www.gnu.org/software/gdb/bugs/... Reading symbols from /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm...done. (gdb) r Starting program: /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm [Thread debugging using libthread_db enabled] Program received signal SIGSEGV, Segmentation fault. 0x0065868c in zend_strndup (s=0x990946 0, length=1) at /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_alloc.c:2615 2615 HANDLE_BLOCK_INTERRUPTIONS(); (gdb) bt #0 0x0065868c in zend_strndup (s=0x990946 0, length=1) at /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_alloc.c:2615 #1 0x0080f418 in fcgi_set_mgmt_var (name=0x990948 FCGI_MPXS_CONNS, name_len=15, value=0x990946 0, value_len=1) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:1113 #2 0x0080d07f in fcgi_init () at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:197 #3 0x0081a93c in main (argc=1, argv=0x7fffe158) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fpm_main.c:1607 2011/6/22 Jérôme Loyet m...@fatbsd.com: Hi it breaks FPM in 5.4 branch on my server: fat@dev:~/dev/php-src/branches/PHP_5_4$ gdb ./sapi/fpm/php-fpm GNU gdb (Ubuntu/Linaro 7.2-1ubuntu11) 7.2 Copyright (C) 2010 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 x86_64-linux-gnu. For bug reporting instructions, please see: http://www.gnu.org/software/gdb/bugs/... Reading symbols from /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm...done. (gdb) run Starting program: /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/php-fpm [Thread debugging using libthread_db enabled] Program received signal SIGSEGV, Segmentation fault. 0x76ec8394 in pthread_mutex_lock () from /lib/x86_64-linux-gnu/libpthread.so.0 (gdb) bt #0 0x76ec8394 in pthread_mutex_lock () from /lib/x86_64-linux-gnu/libpthread.so.0 #1 0x005dc336 in tsrm_mutex_lock (mutexp=0x0) at /home/fat/dev/php-src/branches/PHP_5_4/TSRM/TSRM.c:666 #2 0x005dbaff in ts_resource_ex (id=0, th_id=0x0) at /home/fat/dev/php-src/branches/PHP_5_4/TSRM/TSRM.c:345 #3 0x0065858a in zend_strndup (s=0x98ec46 0, length=1) at /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_alloc.c:2612 #4 0x0080f290 in fcgi_set_mgmt_var (name=0x98ec48 FCGI_MPXS_CONNS, name_len=15, value=0x98ec46 0, value_len=1) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:1109 #5 0x0080cf9f in fcgi_init () at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fastcgi.c:195 #6 0x00818e16 in main (argc=1, argv=0x7fffe158) at /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fpm_main.c:1590 fat@dev:~/dev/php-src/branches/PHP_5_4$ cat config.nice #! /bin/sh # # Created by configure './configure' \ '--disable-all' \ '--enable-fpm' \ '--prefix=/home/fat/php/5.4.x' \ '--enable-session' \ '--enable-phar' \ '--enable-debug' \ '--enable-maintainer-zts' \ $@ the code arround line 1109 in sapi/fpm/fpm/fastcgi.c void fcgi_set_mgmt_var(const char * name, size_t name_len, const char * value, size_t value_len) { zval * zvalue; zvalue = pemalloc(sizeof(*zvalue), 1); Z_TYPE_P(zvalue) = IS_STRING; Z_STRVAL_P(zvalue) = pestrndup(value, value_len, 1); /* -- this line */ Z_STRLEN_P(zvalue) = value_len; zend_hash_add(fcgi_mgmt_vars, name, name_len + 1, zvalue, sizeof(zvalue), NULL); } is there something to change in the call to pestrndup ? ++ Jerome 2011/6/22 Ilia Alshanetsky il...@php.net: iliaa Wed, 22 Jun 2011 14:23:21 + Revision: http://svn.php.net/viewvc?view=revisionrevision=312377 Log: Zend Signal Handling Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/TSRM/TSRM.c U php/php-src/branches/PHP_5_4/TSRM/TSRM.h U php/php-src/branches/PHP_5_4/TSRM/tsrm.m4 U php/php-src/branches/PHP_5_4/Zend/Makefile.am U php/php-src/branches/PHP_5_4/Zend/Zend.m4 U
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS Zend/zend_multiply.h Zend/zend_operators.c Zend/zend_operators.h Zend/zend_vm_def.h Zend/zend_vm_execute.h
Hi dmitry, in Zend/zend_operators.h you have added the offsetof macro. In some case, this macro is already defined and gcc throws a compilation warning: In file included from /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend.h:818:0, from /home/fat/dev/php-src/branches/PHP_5_4/main/php.h:34, from /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fpm_conf.c:30: /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_operators.h:454:0: warning: offsetof redefined /usr/lib/x86_64-linux-gnu/gcc/x86_64-linux-gnu/4.5.2/include/stddef.h:411:0: note: this is the location of the previous definition Can we add a #ifndef offsetof bloc arround the macro definition ? ++ jerome 2011/5/31 Dmitry Stogov dmi...@php.net: dmitry Tue, 31 May 2011 12:05:25 + Revision: http://svn.php.net/viewvc?view=revisionrevision=311662 Log: MFH: Arithmetic speedup. Inlined most probable code-paths for arithmetic operations directly into executor. Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/Zend/zend_multiply.h U php/php-src/branches/PHP_5_4/Zend/zend_operators.c U php/php-src/branches/PHP_5_4/Zend/zend_operators.h U php/php-src/branches/PHP_5_4/Zend/zend_vm_def.h U php/php-src/branches/PHP_5_4/Zend/zend_vm_execute.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS Zend/zend_multiply.h Zend/zend_operators.c Zend/zend_operators.h Zend/zend_vm_def.h Zend/zend_vm_execute.h
Hi, I've added the #ifndef. 2011/6/18 Jérôme Loyet m...@fatbsd.com Hi dmitry, in Zend/zend_operators.h you have added the offsetof macro. In some case, this macro is already defined and gcc throws a compilation warning: In file included from /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend.h:818:0, from /home/fat/dev/php-src/branches/PHP_5_4/main/php.h:34, from /home/fat/dev/php-src/branches/PHP_5_4/sapi/fpm/fpm/fpm_conf.c:30: /home/fat/dev/php-src/branches/PHP_5_4/Zend/zend_operators.h:454:0: warning: offsetof redefined /usr/lib/x86_64-linux-gnu/gcc/x86_64-linux-gnu/4.5.2/include/stddef.h:411:0: note: this is the location of the previous definition Can we add a #ifndef offsetof bloc arround the macro definition ? ++ jerome 2011/5/31 Dmitry Stogov dmi...@php.net: dmitry Tue, 31 May 2011 12:05:25 + Revision: http://svn.php.net/viewvc?view=revisionrevision=311662 Log: MFH: Arithmetic speedup. Inlined most probable code-paths for arithmetic operations directly into executor. Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/Zend/zend_multiply.h U php/php-src/branches/PHP_5_4/Zend/zend_operators.c U php/php-src/branches/PHP_5_4/Zend/zend_operators.h U php/php-src/branches/PHP_5_4/Zend/zend_vm_def.h U php/php-src/branches/PHP_5_4/Zend/zend_vm_execute.h -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- Regards, Felipe Pena
Re: [PHP-CVS] svn: /php/php-src/branches/PHP_5_4/ NEWS Zend/zend_multiply.h Zend/zend_operators.c Zend/zend_operators.h Zend/zend_vm_def.h Zend/zend_vm_execute.h
Le 18 juin 2011 20:12, Felipe Pena felipe...@gmail.com a écrit : Hi, I've added the #ifndef. thanks you -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/standard/filestat.c branches/PHP_5_4/ext/standard/tests/file/userstreams_007.phpt branches/PHP_5_4/main/php_streams.h branch
On Wed, May 25, 2011 at 23:24, Stas Malyshev smalys...@gmail.com wrote: Hi! There seem to be a lot of unrelated code cleanup here, and I am in general a bit confused in this code. Could you review http://php.net/streamwrapper and write up the changes to it? There shouldn't be any changes except for adding one stream handler (see rfc: https://wiki.php.net/rfc/streammetadata) and adding support for it. I'll add docs for it soon. Kudos. -Hannes -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/standard/filestat.c branches/PHP_5_4/ext/standard/tests/file/userstreams_007.phpt branches/PHP_5_4/main/php_streams.h branch
There seem to be a lot of unrelated code cleanup here, and I am in general a bit confused in this code. Could you review http://php.net/streamwrapper and write up the changes to it? -Hannes On Wed, May 25, 2011 at 23:03, Stanislav Malyshev s...@php.net wrote: stas Wed, 25 May 2011 21:03:55 + Revision: http://svn.php.net/viewvc?view=revisionrevision=311422 Log: implement streams metadata API per RFC Changed paths: U php/php-src/branches/PHP_5_4/NEWS U php/php-src/branches/PHP_5_4/ext/standard/filestat.c A php/php-src/branches/PHP_5_4/ext/standard/tests/file/userstreams_007.phpt U php/php-src/branches/PHP_5_4/main/php_streams.h U php/php-src/branches/PHP_5_4/main/streams/plain_wrapper.c U php/php-src/branches/PHP_5_4/main/streams/userspace.c U php/php-src/trunk/ext/standard/filestat.c A php/php-src/trunk/ext/standard/tests/file/userstreams_007.phpt U php/php-src/trunk/main/php_streams.h U php/php-src/trunk/main/streams/plain_wrapper.c U php/php-src/trunk/main/streams/userspace.c -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/standard/filestat.c branches/PHP_5_4/ext/standard/tests/file/userstreams_007.phpt branches/PHP_5_4/main/php_streams.h branch
Hi! There seem to be a lot of unrelated code cleanup here, and I am in general a bit confused in this code. Could you review http://php.net/streamwrapper and write up the changes to it? There shouldn't be any changes except for adding one stream handler (see rfc: https://wiki.php.net/rfc/streammetadata) and adding support for it. I'll add docs for it soon.
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/standard/filestat.c branches/PHP_5_4/ext/standard/tests/file/userstreams_007.phpt branches/PHP_5_4/main/php_streams.h branch
hi, Besides that, did we even approve that change? Gustavo and I were two that did not like the current implemenation/design. Cheers, On Wed, May 25, 2011 at 11:24 PM, Stas Malyshev smalys...@gmail.com wrote: Hi! There seem to be a lot of unrelated code cleanup here, and I am in general a bit confused in this code. Could you review http://php.net/streamwrapper and write up the changes to it? There shouldn't be any changes except for adding one stream handler (see rfc: https://wiki.php.net/rfc/streammetadata) and adding support for it. I'll add docs for it soon. -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/standard/filestat.c branches/PHP_5_4/ext/standard/tests/file/userstreams_007.phpt branches/PHP_5_4/main/php_streams.h branch
Hi! Besides that, did we even approve that change? Gustavo and I were two that did not like the current implemenation/design. There were no objections and/or proposals for improving it since I posted the patch, which as about 2 months ago, so I assumed it's ok. If you have any specific ideas how to improve it, please tell. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/standard/filestat.c branches/PHP_5_4/ext/standard/tests/file/userstreams_007.phpt branches/PHP_5_4/main/php_streams.h branch
On Thu, May 26, 2011 at 12:04 AM, Stas Malyshev smalys...@sugarcrm.com wrote: Hi! Besides that, did we even approve that change? Gustavo and I were two that did not like the current implemenation/design. There were no objections and/or proposals for improving it since I posted the patch, which as about 2 months ago, so I assumed it's ok. If you have any specific ideas how to improve it, please tell. No time to actually proper design and propose alternatives yet. That does mean we have to accept something just because it is ready. Sorry -- Pierre @pierrejoye | http://blog.thepimp.net | http://www.libgd.org -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP-CVS] svn: /php/php-src/ branches/PHP_5_4/NEWS branches/PHP_5_4/ext/standard/filestat.c branches/PHP_5_4/ext/standard/tests/file/userstreams_007.phpt branches/PHP_5_4/main/php_streams.h branch
Hi! No time to actually proper design and propose alternatives yet. That does mean we have to accept something just because it is ready. Sorry No, I think if we have working solution for a real problem, even if it's not perfect - it is the reason to use it and I can vaguely imagine something better but nobody would ever actually do it is not a valid reason to reject it. If there's some real problem - fine, but just because of imaginary better solution that would never happen - I don't think it makes any sense, sorry. -- Stanislav Malyshev, Software Architect SugarCRM: http://www.sugarcrm.com/ (408)454-6900 ext. 227 -- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php