Review 10.4 Merged

72149[BUGFIX] Fix too long regular expression error in ContentObjectRenderer

Christian Kuhn CR +2 V +2 Normal +60 −19 updated 11/10/21, 19:23

Commit message

Text cropping on texts with way more than 1000 characters
triggers regular expression compilation errors.
The sweet spot was determined to a value of max 962 characters,
thus leading to internal 'preg_match' error state and throwing
'Compilation failed: regular expression is too large' warning.

The patch crops text in multiple chunks and reassembles the
chunks until crop position was reached to avoid this internal
error exceeding the max regular expression pattern length.

Further tests are added to cover this scenario.

Review

  • Code review CR +2 Done
    • Christian Kuhn +2
  • Verified V +2 Done
    • Christian Kuhn +2
    • core-ci +1 CI

Issues 1

Files 2

Review log 34

  1. Christian Kuhn uploaded patch set 1 11/10/21, 18:57

  2. core-ci voted on patch set 1 V +1 11/10/21, 19:05 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/19143

  3. Christian Kuhn voted on patch set 1 V +2 CR +2 11/10/21, 19:23

  4. Christian Kuhn merged patch set 2 11/10/21, 19:23