Your message dated Thu, 14 Jan 2016 23:17:08 +0000 with message-id <[email protected]> and subject line Bug#798727: fixed in perl 5.20.2-3+deb8u3 has caused the Debian Bug report #798727, regarding Encode::Unicode decode() dies unnecessarily to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [email protected] immediately.) -- 798727: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=798727 Debian Bug Tracking System Contact [email protected] with problems
--- Begin Message ---Package: perl Version: 5.20.2-2 The Encode::Unicode documentation states the following: When BE or LE is omitted during decode(), it checks if BOM is at the beginning of the string; if one is found, the endianness is set to what the BOM says. If no BOM is found, the routine dies. To reproduce: --- use Encode qw/decode/; decode("utf-16be", "Hello World"); # does not die decode("utf-16le", "Hello World"); # does not die decode("utf-16", "\xFE\xFFHello World"); # does not die decode("utf-16", "Hello World"); # dies with "UTF-16:Unrecognised BOM" --- Unicode Standard version 8.0: The UTF-16 encoding scheme may or may not begin with a BOM. However, when there is no BOM, and in the absence of a higher-level protocol, the byte order of the UTF-16 encoding scheme is big-endian. RFC2781: If the first two octets of the text is not 0xFE followed by 0xFF, and is not 0xFF followed by 0xFE, then the text SHOULD be interpreted as being big-endian. There is a simple fix of doing nothing: diff --git a/cpan/Encode/Unicode/Unicode.xs b/cpan/Encode/Unicode/Unicode.xs index cf42ab8..7caf1c1 100644 --- a/cpan/Encode/Unicode/Unicode.xs +++ b/cpan/Encode/Unicode/Unicode.xs @@ -164,9 +164,18 @@ CODE: endian = 'V'; } else { - croak("%"SVf":Unrecognised BOM %"UVxf, - *hv_fetch((HV *)SvRV(obj),"Name",4,0), - bom); + /* No BOM found, use big-endian fallback as specified in + * RFC2781 and the Unicode Standard version 8.0: + * + * The UTF-16 encoding scheme may or may not begin with + * a BOM. However, when there is no BOM, and in the + * absence of a higher-level protocol, the byte order + * of the UTF-16 encoding scheme is big-endian. + * + * If the first two octets of the text is not 0xFE + * followed by 0xFF, and is not 0xFF followed by 0xFE, + * then the text SHOULD be interpreted as big-endian. + */ } } #if 1 CPAN bug report: https://rt.cpan.org/Ticket/Display.html?id=107043
--- End Message ---
--- Begin Message ---Source: perl Source-Version: 5.20.2-3+deb8u3 We believe that the bug you reported is fixed in the latest version of perl, which is due to be installed in the Debian FTP archive. A summary of the changes between this version and the previous one is attached. Thank you for reporting the bug, which will now be closed. If you have further comments please address them to [email protected], and the maintainer will reopen the bug report if appropriate. Debian distribution maintenance software pp. Dominic Hargreaves <[email protected]> (supplier of updated perl package) (This message was generated automatically at their request; if you believe that there is a problem with it please contact the archive administrators by mailing [email protected]) -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Format: 1.8 Date: Mon, 11 Jan 2016 23:06:58 +0000 Source: perl Binary: perl-base perl-doc perl-debug libperl5.20 libperl-dev perl-modules perl Architecture: all amd64 source Version: 5.20.2-3+deb8u3 Distribution: jessie Urgency: medium Maintainer: Niko Tyni <[email protected]> Changed-By: Dominic Hargreaves <[email protected]> Closes: 798727 Description: libperl5.20 - shared Perl library libperl-dev - Perl library: development files perl-base - minimal Perl system perl-debug - debug-enabled Perl interpreter perl-doc - Perl documentation perl - Larry Wall's Practical Extraction and Report Language perl-modules - Core Perl modules Changes: perl (5.20.2-3+deb8u3) jessie; urgency=medium . * Backport Encode::Unicode BOM fix from Encode-2.77. (Closes: #798727) + break+replace libencode-perl (<< 2.63-1+deb8u1) accordingly Checksums-Sha1: 47fedcfa859b1ed1f26886cdf023d4a3cea48cb0 2324 perl_5.20.2-3+deb8u3.dsc 9a8107c5097ca8bdcee58c081f6b4b337aed091a 109676 perl_5.20.2-3+deb8u3.debian.tar.xz d7c570a12e0b693f179802c92d6a3479c14a5938 7343828 perl-doc_5.20.2-3+deb8u3_all.deb 2cc8f3d28412bd0807e6684ad27e60663a06dcc6 2545178 perl-modules_5.20.2-3+deb8u3_all.deb 0904dea7ac9f78e458d04b6c453230008a4cd690 1223222 perl-base_5.20.2-3+deb8u3_amd64.deb 1cfbd98949d490927c2ccc69e2156068df855866 4514784 perl-debug_5.20.2-3+deb8u3_amd64.deb 21f5f6fcb1df8f64855c0d3fcb19eaf192221ecd 1354 libperl5.20_5.20.2-3+deb8u3_amd64.deb 11de76bc1eba14a41fd8c7f4a5a51803a5cc92e0 2150746 libperl-dev_5.20.2-3+deb8u3_amd64.deb f219e3f30c48a1c516d337de8e1e3eddb8cb98fc 2654854 perl_5.20.2-3+deb8u3_amd64.deb Checksums-Sha256: 129d2380b581b533fbe46cdacbef9391e72693940eb3ac81dfd28d591b69db3c 2324 perl_5.20.2-3+deb8u3.dsc ab2b5c5131517695fbb94b213e0edb77b9169b5b16e72ce74a97ba5cb2c64cd8 109676 perl_5.20.2-3+deb8u3.debian.tar.xz 845f262854e92fc78bd9458df4fce17ba8662e27faa1da2672a24d3ae6eaea22 7343828 perl-doc_5.20.2-3+deb8u3_all.deb 1f77660effa0f26f2f8b1f452964a690a9432b0717383601898ca25bf7b893d1 2545178 perl-modules_5.20.2-3+deb8u3_all.deb f74bdd736e51947358ef5a9974db30a45751df9bef94cba97a77050eeea4c88c 1223222 perl-base_5.20.2-3+deb8u3_amd64.deb d8112c873568c064d3ca05b0f1256e43349646bc7e1219e3472434e29fc42403 4514784 perl-debug_5.20.2-3+deb8u3_amd64.deb 00848ca11fce066ce5350f9913344dda0a1a802a0637acff6a2babf59f91bb35 1354 libperl5.20_5.20.2-3+deb8u3_amd64.deb 60f328ced746db2684d6cb95016bb01f6b5afa0768d43d51a72d3ea3e24dd920 2150746 libperl-dev_5.20.2-3+deb8u3_amd64.deb 51a8d51f2cc522004d3fe472f6e4acac94c69d83586511353e0413b680f460ef 2654854 perl_5.20.2-3+deb8u3_amd64.deb Files: a30e1f473e23c23a546b122a1d8f66d4 2324 perl standard perl_5.20.2-3+deb8u3.dsc 310212c09195186b6ad925ae51301ba4 109676 perl standard perl_5.20.2-3+deb8u3.debian.tar.xz 47de3b201f46ff76c5647f28a3604fa5 7343828 doc optional perl-doc_5.20.2-3+deb8u3_all.deb cc6b9bed8f374b10749edf588b87faea 2545178 perl standard perl-modules_5.20.2-3+deb8u3_all.deb 5c5dde8af28cfee2529e36c353d655de 1223222 perl required perl-base_5.20.2-3+deb8u3_amd64.deb b3bfd06098ff84728f62b2392a0f70e4 4514784 debug extra perl-debug_5.20.2-3+deb8u3_amd64.deb 45c5d69a7e17d0993d5a2ed5db898cae 1354 libs optional libperl5.20_5.20.2-3+deb8u3_amd64.deb c8de8b85956db04eee12a092804cca47 2150746 libdevel optional libperl-dev_5.20.2-3+deb8u3_amd64.deb ecabbf44a9c954a683b7ef046cc207b0 2654854 perl standard perl_5.20.2-3+deb8u3_amd64.deb -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCAAGBQJWlD5VAAoJEMAFfnFNaU+yJTAQAIVUFSVsu2FJjzjQbBjZ55SO kSI8OhCyPuKrWNTRTRZj0mUKbLYV6CPd8t4Mq9x+lbUlAKA1oDfOWJccjYJtVyza 9CmssfvHpSKYUShgsJSeC7dgnPCrnPqL/krMkaWdUVzwAkrVZZbT2rmrxB5MosCi 8/dGpR9I1Yp0DMeNyhBagO2ibylCFi8ZVNHkiZ7vbC3f9Ab1AqMn0B1gyQ2AEnnv x8woCr4tj32XSXab+HnetUjrnGP7lpaVzgOP70BbWwfBUvXZIP0ibk3mMit7nvW7 3H4lghHf3Q0tboBF/TuGU23TeKx90UgERx8gE7N8ckuZ7PhuupcHnNbgGF2e/rix Zpa+5+WJqD5dL4R2OeV/0g1GIPAtD957k2iBps0EpvoqWjbqBQGGmm32OByxM+ts Cmos+GzTfj/KywEOoYiExgXkvYzysdRbgUCqKsMvO+/hubSoyH3eBgrjmDkjPmiw pqUDEop+NhJfswAtdfcixUDNJXf9ANo3IDk5x/hVH0TUz0WrCmrmvgEA9hShoUhZ 4rQ12f605LXhFoEDgoIutshmMW8rz8ieq8PQaXfu3Kp/bJZNnjR3mf3x6fluBlrm JDVGIiL+gvNZUxrh2YlbVGuwoxxPmGtHAVBytqUa6JV6zZduY7kCk+U2ozFrKaEH wv3/FlxXTlPGRTikhqef =5tx3 -----END PGP SIGNATURE-----
--- End Message ---

