[TYPO3-core] RFC #12230: Bug: Function tslib_cObj::crop() is not fully multibyte safe

Sebastian Fischer sf at marketing-factory.de
Mon Jan 31 16:15:04 CET 2011


On 31.01.2011 12:18, Vladimir Podkovanov wrote:
> This is an SVN patch request.
>
> Type: Bugfix
>
> Bugtracker reference: http://bugs.typo3.org/view.php?id=12230
>
> Branches: TYPO3_4-4, TYPO3_4-5, trunk
>
> Problem:
> tslib_cObj::crop() use not multibyte safe strlen() to determine if
> string should be cropped it results in needless afterstring (...) even
> if string wasn't truncated.
>
> Solution:
> Use multibyte safe strlen()
>

Hi Vladimir,

+1 for the check of length with csconvobj.

-1 on changing the concatination in a ternary. There is no improvement 
by putting the hole in one line. Neither does it improve readbility nor 
any performance.

So in total a -1 until this is removed.

Greetings
Sebastian


More information about the TYPO3-team-core mailing list