File tree Expand file tree Collapse file tree 2 files changed +2
-8
lines changed Expand file tree Collapse file tree 2 files changed +2
-8
lines changed Original file line number Diff line number Diff line change @@ -461,9 +461,7 @@ mbfl_strlen(const mbfl_string *string)
461
461
string -> encoding ,
462
462
& mbfl_encoding_wchar ,
463
463
filter_count_output , 0 , & len );
464
- if (filter == NULL ) {
465
- return (size_t ) -1 ;
466
- }
464
+ ZEND_ASSERT (filter );
467
465
/* count */
468
466
n = string -> len ;
469
467
p = string -> val ;
Original file line number Diff line number Diff line change @@ -1823,11 +1823,7 @@ PHP_FUNCTION(mb_strlen)
1823
1823
RETURN_THROWS ();
1824
1824
}
1825
1825
1826
- size_t n = mbfl_strlen (& string );
1827
- /* Only way this can fail is if the conversion creation fails
1828
- * this would imply some sort of memory allocation failure which is a bug */
1829
- ZEND_ASSERT (!mbfl_is_error (n ));
1830
- RETVAL_LONG (n );
1826
+ RETVAL_LONG (mbfl_strlen (& string ));
1831
1827
}
1832
1828
/* }}} */
1833
1829
You can’t perform that action at this time.
0 commit comments