… | |
… | |
25 | #include "encoding.h" |
25 | #include "encoding.h" |
26 | |
26 | |
27 | #include <cstdlib> |
27 | #include <cstdlib> |
28 | #include <cstring> |
28 | #include <cstring> |
29 | |
29 | |
30 | const struct n2cs { |
30 | static const struct n2cs { |
31 | const char *name; |
31 | const char *name; |
32 | codeset cs; |
32 | codeset cs; |
33 | } n2cs[] = { |
33 | } n2cs[] = { |
34 | /* first one found is the normalized one */ |
34 | /* first one found is the normalized one */ |
35 | { "ISO88591", CS_ISO8859_1 }, |
35 | { "ISO88591", CS_ISO8859_1 }, |
… | |
… | |
57 | { "UTF8", CS_UNICODE }, |
57 | { "UTF8", CS_UNICODE }, |
58 | |
58 | |
59 | { "ASCII", CS_US_ASCII }, |
59 | { "ASCII", CS_US_ASCII }, |
60 | { "USASCII", CS_US_ASCII }, |
60 | { "USASCII", CS_US_ASCII }, |
61 | { "ANSIX341968", CS_US_ASCII }, |
61 | { "ANSIX341968", CS_US_ASCII }, |
62 | { "ISO646.1991-IRV", CS_US_ASCII }, // older versions used the currency sign |
62 | { "ISO6461991IRV", CS_US_ASCII }, // older versions used the currency sign |
63 | |
63 | |
64 | { "KOI8R*", CS_KOI8_R }, |
64 | { "KOI8R*", CS_KOI8_R }, |
65 | { "GOST1976874*", CS_KOI8_R }, |
65 | { "GOST1976874*", CS_KOI8_R }, |
66 | { "KOI8RU", CS_KOI8_U }, |
66 | { "KOI8RU", CS_KOI8_U }, |
67 | { "KOI8U", CS_KOI8_U }, |
67 | { "KOI8U", CS_KOI8_U }, |