File tree Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Expand file tree Collapse file tree 2 files changed +7
-11
lines changed Original file line number Diff line number Diff line change @@ -2092,17 +2092,13 @@ Perl_utf8_to_uv_msgs_helper_(const U8 * const s0,
2092
2092
case UTF8_GOT_LONG :
2093
2093
* errors |= UTF8_GOT_LONG ;
2094
2094
2095
- if (flags & UTF8_ALLOW_LONG ) {
2096
-
2097
- /* We don't allow the actual overlong value, unless the
2098
- * special extra bit is also set */
2099
- if (! (flags & ( UTF8_ALLOW_LONG_AND_ITS_VALUE
2100
- & ~UTF8_ALLOW_LONG )))
2101
- {
2102
- uv = UNICODE_REPLACEMENT ;
2103
- }
2095
+ if (! (flags & UTF8_ALLOW_LONG_AND_ITS_VALUE )) {
2096
+ uv = UNICODE_REPLACEMENT ;
2104
2097
}
2105
- else {
2098
+
2099
+ if (! (flags & ( UTF8_ALLOW_LONG
2100
+ |UTF8_ALLOW_LONG_AND_ITS_VALUE )))
2101
+ {
2106
2102
disallowed = TRUE;
2107
2103
2108
2104
if (NEED_MESSAGE (WARN_UTF8 ,,)) {
Original file line number Diff line number Diff line change @@ -1201,7 +1201,7 @@ point's representation.
1201
1201
* First one will convert the overlong to the REPLACEMENT CHARACTER; second
1202
1202
* will return what the overlong evaluates to */
1203
1203
#define UTF8_ALLOW_LONG 0x2000
1204
- #define UTF8_ALLOW_LONG_AND_ITS_VALUE (UTF8_ALLOW_LONG| 0x4000)
1204
+ #define UTF8_ALLOW_LONG_AND_ITS_VALUE 0x4000
1205
1205
#define UTF8_GOT_LONG UTF8_ALLOW_LONG
1206
1206
1207
1207
/* For back compat, these old names are misleading for overlongs and
You can’t perform that action at this time.
0 commit comments