Refactoring according to CR: strlen -> mb_strlen