NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

lib/42209: various problems with EBCDIC support in iconv(3)



>Number:         42209
>Category:       lib
>Synopsis:       various problems with EBCDIC support in iconv(3)
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    lib-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Oct 21 15:25:00 +0000 2009
>Originator:     Matthias Drochner
>Release:        current
>Organization:
>Environment:
i386/-current
>Description:
The selftests of pkgsrc/libxml2 fail for a couple of reasons:
1. EBCDIC-US is not recognized as charset name
2. newline characters are not translated for most EBCDIC codepages
   (other control characters are appearently affected as well)
3. There is no support for CP1141 (which is CP273 + EUR character)
   (This should be called IBM01141 according to
    http://www.iana.org/assignments/character-sets)

>How-To-Repeat:
for problem 2:
$ printf "\x25"|iconv -f EBCDIC-UK -t ascii|hexdump -C
iconv: iconv(): Illegal byte sequence
$ printf "\n"|iconv -t EBCDIC-UK -f ascii|hexdump -C
00000000  0a                                                |.|
00000001

>Fix:
This seems to fix CP273:
--- share/i18n/csmapper/CP/CP273%UCS.src        
b7faa80dfb97da879459d1c88098cc897db4c9c4
+++ share/i18n/csmapper/CP/CP273%UCS.src        
84af089511d0acff6677765723d0adb042e6147e
@@ -43,6 +43,7 @@ 0x1F = 0x001F
 0x1D = 0x001D
 0x1E = 0x001E
 0x1F = 0x001F
+0x25 = 0x000A
 0x40 = 0x0020
 0x41 = 0x00A0
 0x42 = 0x00E2
============================================================
--- share/i18n/csmapper/CP/UCS%CP273.src        
1569837a5ac966a9760459aa83e4226ac5d4a781
+++ share/i18n/csmapper/CP/UCS%CP273.src        
9ef05f6f253612340959f2d1959e53354cec8150
@@ -21,7 +21,7 @@ 0x0009 = 0x09
 0x0007 = 0x07
 0x0008 = 0x08
 0x0009 = 0x09
-0x000A = 0x0A
+0x000A = 0x25
 0x000B = 0x0B
 0x000C = 0x0C
 0x000D = 0x0D



Home | Main Index | Thread Index | Old Index