This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
utf8.c: Fix bugs with overlongs combined with other malformations.
The code handling the UTF-8 overlong malformation must come after
handling all the other malformations. This is because it may change the
code point represented to the REPLACEMENT CHARACTER. The other
malformation code is expecting the code point to be the original one.
This may cause failure to catch and report other malformations, or
report the wrong value of the erroneous code point.
What was needed was simply to move the 'if else' branch for overlongs to
after the branches for the other formations.