Build: #440 was successful Changes by Marc

Code commits

phpBB 3.3.x

  • Marc

    Marc 4bf78fd7fdf89da0831bf94b678da2d36a662e20

    Merge pull request #6465 from LukeWCS/ticket/17076
    [ticket/17076] Fix signature length calculation

  • LukeWCS

    LukeWCS 1f96a2c79a61ab7c348103a1d4530aa0b85976f0 m

    [ticket/17076] Fix signature length calculation
    The error occurs when BBcode is used but there is no whitespace. In this case,
    a part of the RegEx that is designed to be greedy is responsible for selecting
    all BBcode tag containers and their content that do not contain whitespace.
    This, in combination with the replace string, effectively reduces the entire
    signature to a single space. This is the explanation for the reported behavior
    of phpBB.

    In addition, the bug also generally prevents the correct removal of BBcode
    containers if their content does not contain whitespace. In such cases, the
    BBcode tags are removed along with the content, which also results in
    incorrect calculation of the text length.

    * Changed the corresponding RegEx part from greedy to non-greedy.
    * Removed an unnecessary class definition.
    * Changed an unnecessary capturing group to a non-capturing group.
    * Changed the replace string from a space to an empty string. <- Here,
    however, I'm not sure if the space was intentional or not!

    PHPBB3-17076

    • phpBB/includes/message_parser.php (version 1f96a2c79a61ab7c348103a1d4530aa0b85976f0)