aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/c_subst.c19
-rw-r--r--src/c_subst.h4
-rw-r--r--src/c_unixize.c3
3 files changed, 25 insertions, 1 deletions
diff --git a/src/c_subst.c b/src/c_subst.c
index 0291dc7..de09514 100644
--- a/src/c_subst.c
+++ b/src/c_subst.c
@@ -311,6 +311,25 @@ c_unicode_subst(char filename[])
);
c_unicode_subst(filename);
}
+ if (u_isucharset((unsigned char)*(p + 1), C_CHARSET_Y) == TRUE) {
+ *p = 'y';
+ memmove(
+ p + 1,
+ p + 2,
+ (strlen((const char*)p + 2) + 1) * sizeof(char)
+ );
+ c_unicode_subst(filename);
+ }
+ if (u_isucharset((unsigned char)*(p + 1), C_CHARSET_TH) == TRUE) {
+ *p = 't';
+ *(p + 1) = 'h';
+ c_unicode_subst(filename);
+ }
+ if (*(p + 1) == 0x9f) {
+ *p = 's';
+ *(p + 1) = 'z';
+ c_unicode_subst(filename);
+ }
}
if (*p == 0xce) {
if (*(p + 1) == 0xbc) {
diff --git a/src/c_subst.h b/src/c_subst.h
index 124dcf5..00073b2 100644
--- a/src/c_subst.h
+++ b/src/c_subst.h
@@ -61,6 +61,8 @@
"\x91\xb1"
#define C_CHARSET_DH \
"\x90\xb0"
+#define C_CHARSET_TH \
+ "\x9e\xbe"
#define C_CHARSET_C \
"\x87\xa7"
#define C_CHARSET_E \
@@ -69,6 +71,8 @@
"\x99\x9a\x9b\x9c\xb9\xba\xbb\xbc"
#define C_CHARSET_I \
"\x8c\x8d\x8e\x8f\xac\xab\xac\xad"
+#define C_CHARSET_Y \
+ "\x9d\xbd\xbf"
struct lfiles_s* c_subst_filenames(struct lfiles_s*, const bool_t,
const bool_t, const unsigned char);
diff --git a/src/c_unixize.c b/src/c_unixize.c
index eac2eb3..1866ac7 100644
--- a/src/c_unixize.c
+++ b/src/c_unixize.c
@@ -133,7 +133,8 @@ main
og_files->filename,
new_files->filename,
strlen(new_files->filename) + 1
- ) != 0
+ ) != 0 &&
+ new_files->filename[0] != 0x00
) {
if (opts.verbose == TRUE) {
dprintf(