History log of /PHP-8.2/ext/mbstring/tests/bug81298.phpt (Results 1 – 4 of 4)
Revision Date Author Comments
# a2bc57e0 18-Oct-2021 Alex Dowad

mb_detect_encoding will not return non-encodings

Among the text encodings supported by mbstring are several which are
not really 'text encodings'. These include Base64, QPrint, UUencode,

mb_detect_encoding will not return non-encodings

Among the text encodings supported by mbstring are several which are
not really 'text encodings'. These include Base64, QPrint, UUencode,
HTML entities, '7 bit', and '8 bit'.

Rather than providing an explicit list of text encodings which they are
interested in, users may pass the output of mb_list_encodings to
mb_detect_encoding. Since Base64, QPrint, and so on are included in
the output of mb_list_encodings, mb_detect_encoding can return one of
these as its 'detected encoding' (and in fact, this often happens).
Before mb_detect_encoding was enhanced so it could detect any of the
supported text encodings, this did not happen, and it is never desired.

show more ...


# 89aa42c7 28-Jul-2021 Nikita Popov

Add missing EXTENSIONS section


# a1c1ee6a 28-Jul-2021 Nikita Popov

Don't use opaque for encoding detection score

opaque is used by the htmlentities filter, which means that we
end up trying to free the score value as a pointer. Don't try to
be overl

Don't use opaque for encoding detection score

opaque is used by the htmlentities filter, which means that we
end up trying to free the score value as a pointer. Don't try to
be overly tricky here and simply allocate a separate structure
to hold the number of illegal characters and the score.

show more ...


# 9d0db2e9 28-Jul-2021 Nikita Popov

Fixed bug #81298

Creation of the filter may fail for some special encodings, for
which detection is not supported.