I'm going to fix this shortly. Thank you for the heads-up. Moriyoshi
On 2/14/09, Antony Dovgal <[email protected]> wrote: > On 14.02.2009 10:35, Moriyoshi Koizumi wrote: >> moriyoshi Sat Feb 14 07:35:01 2009 UTC >> >> Added files: (Branch: PHP_5_2) >> /php-src/ext/mbstring/tests bug45923.phpt >> >> Modified files: >> /php-src NEWS >> /php-src/ext/mbstring mbstring.c >> /php-src/ext/mbstring/libmbfl/mbfl mbfilter.c >> Log: >> - MFH: Fix Bug #45923 (mb_st[r]ripos() offset not handled correctly) > > This change (E_NOTICE -> E_WARNING) makes 12 tests to fail. > > --------------------------- > - if ((offset > 0 && offset > mbfl_strlen(&haystack)) || > - (offset < 0 && -offset > mbfl_strlen(&haystack))) { > - php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Offset is greater > than the > length of haystack string"); > - RETURN_FALSE; > + { > + int haystack_char_len = mbfl_strlen(&haystack); > + if ((offset > 0 && offset > haystack_char_len) || > + (offset < 0 && -offset > haystack_char_len)) { > + php_error_docref(NULL TSRMLS_CC, E_WARNING, "Offset is > greater than the > length of haystack string"); > + RETURN_FALSE; > + } > } > --------------------------- > > -- > Wbr, > Antony Dovgal > > -- > 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
