summaryrefslogtreecommitdiff
path: root/src/locale
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2013-06-26 14:27:45 -0400
committerRich Felker <dalias@aerifal.cx>2013-06-26 14:27:45 -0400
commit6a4cfbdbe718a115a22629ad0cb2ae21391a0454 (patch)
tree0a47fc0bc27b82a29b432c0f41c125fa25613220 /src/locale
parent59b481d9702e6e09699ce22710ea150eb97c19d5 (diff)
downloadmusl-6a4cfbdbe718a115a22629ad0cb2ae21391a0454.tar.gz
musl-6a4cfbdbe718a115a22629ad0cb2ae21391a0454.tar.bz2
musl-6a4cfbdbe718a115a22629ad0cb2ae21391a0454.tar.xz
musl-6a4cfbdbe718a115a22629ad0cb2ae21391a0454.zip
fix iconv conversion to legacy 8bit codepages
this seems to have been a simple copy-and-paste error from the code for converting from legacy codepages.
Diffstat (limited to 'src/locale')
-rw-r--r--src/locale/iconv.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/locale/iconv.c b/src/locale/iconv.c
index 7b341fe9..a2332ce0 100644
--- a/src/locale/iconv.c
+++ b/src/locale/iconv.c
@@ -316,8 +316,8 @@ size_t iconv(iconv_t cd0, char **restrict in, size_t *restrict inb, char **restr
}
d = c;
for (c=0; c<128-totype; c++) {
- if (d == legacy_chars[ map[c*5/4]>>2*c%8 |
- map[c*5/4+1]<<8-2*c%8 & 1023 ]) {
+ if (d == legacy_chars[ tomap[c*5/4]>>2*c%8 |
+ tomap[c*5/4+1]<<8-2*c%8 & 1023 ]) {
c += 128;
goto revout;
}