aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fs/isofs/joliet.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/fs/isofs/joliet.c b/fs/isofs/joliet.c
index 81a90e170ac3..fb8fe7a9ddc6 100644
--- a/fs/isofs/joliet.c
+++ b/fs/isofs/joliet.c
@@ -14,9 +14,9 @@
14 * Convert Unicode 16 to UTF-8 or ASCII. 14 * Convert Unicode 16 to UTF-8 or ASCII.
15 */ 15 */
16static int 16static int
17uni16_to_x8(unsigned char *ascii, u16 *uni, int len, struct nls_table *nls) 17uni16_to_x8(unsigned char *ascii, __be16 *uni, int len, struct nls_table *nls)
18{ 18{
19 wchar_t *ip, ch; 19 __be16 *ip, ch;
20 unsigned char *op; 20 unsigned char *op;
21 21
22 ip = uni; 22 ip = uni;
@@ -24,8 +24,8 @@ uni16_to_x8(unsigned char *ascii, u16 *uni, int len, struct nls_table *nls)
24 24
25 while ((ch = get_unaligned(ip)) && len) { 25 while ((ch = get_unaligned(ip)) && len) {
26 int llen; 26 int llen;
27 ch = be16_to_cpu(ch); 27 llen = nls->uni2char(be16_to_cpu(ch), op, NLS_MAX_CHARSET_SIZE);
28 if ((llen = nls->uni2char(ch, op, NLS_MAX_CHARSET_SIZE)) > 0) 28 if (llen > 0)
29 op += llen; 29 op += llen;
30 else 30 else
31 *op++ = '?'; 31 *op++ = '?';
@@ -82,7 +82,7 @@ get_joliet_filename(struct iso_directory_record * de, unsigned char *outname, st
82 len = wcsntombs_be(outname, de->name, 82 len = wcsntombs_be(outname, de->name,
83 de->name_len[0] >> 1, PAGE_SIZE); 83 de->name_len[0] >> 1, PAGE_SIZE);
84 } else { 84 } else {
85 len = uni16_to_x8(outname, (u16 *) de->name, 85 len = uni16_to_x8(outname, (__be16 *) de->name,
86 de->name_len[0] >> 1, nls); 86 de->name_len[0] >> 1, nls);
87 } 87 }
88 if ((len > 2) && (outname[len-2] == ';') && (outname[len-1] == '1')) { 88 if ((len > 2) && (outname[len-2] == ';') && (outname[len-1] == '1')) {