Hello php-dev,
I found workaround for 13901 bug, but because i very bad know php internals,
i think php-developers must verify this code:
--cut--
*** string.c.org Sun Nov 11 01:14:08 2001
--- string.c Sun Nov 11 01:12:00 2001
*************** PHPAPI char *php_str_to_str(char *haysta
*** 2143,2148 ****
--- 2143,2157 ----
char *end = haystack + length;
smart_str result = {0};
+ if(!length){
+ smart_str_appendl(&result, "", 0);
+ smart_str_0(&result);
+ if (_new_length) *_new_length = result.len;
+ return result.c;
+ }
+
for (p = haystack;
(r = php_memnstr(p, needle, needle_len, end));
p = r + needle_len) {
--cut--
Best regards,
Andrew Sitnikov
e-mail : [EMAIL PROTECTED]
GSM: (+372) 56491109
--
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]