]> arthur.barton.de Git - netatalk.git/commitdiff
remove ATALK_MAC_CHARSET and ATALK_UNIX_CHARSET
authorHAT <hat@fa2.so-net.ne.jp>
Wed, 14 Mar 2012 13:04:00 +0000 (22:04 +0900)
committerHAT <hat@fa2.so-net.ne.jp>
Wed, 14 Mar 2012 13:04:00 +0000 (22:04 +0900)
libatalk/unicode/charcnv.c

index 7859a228ea1f9756b4a6c5fd72dc585eeff1aadf..86f29c6a77972de00a151d9d1f57b0767993d1b9 100644 (file)
@@ -78,29 +78,6 @@ static struct charset_functions* charsets[MAX_CHARSETS];
 static char hexdig[] = "0123456789abcdef";
 #define hextoint( c )   ( isdigit( c ) ? c - '0' : c + 10 - 'a' )
 
-static char* read_charsets_from_env(charset_t ch)
-{
-    char *name;
-
-    switch (ch) {
-    case CH_MAC:
-        if (( name = getenv( "ATALK_MAC_CHARSET" )) != NULL )
-            return name;
-        else
-            return "MAC_ROMAN";
-        break;
-    case CH_UNIX:
-        if (( name = getenv( "ATALK_UNIX_CHARSET" )) != NULL )
-            return name;
-        else
-            return "LOCALE";
-        break;
-    default:
-        break;
-    }
-    return "ASCII";
-}
-
 
 /**
  * Return the name of a charset to give to iconv().
@@ -123,7 +100,7 @@ static const char *charset_name(charset_t ch)
     else if (ch == CH_UTF8_MAC) ret = "UTF8-MAC";
     else if (ch == CH_UNIX) {
         if (unixname[0] == '\0') {
-            ret = read_charsets_from_env(CH_UNIX);
+            ret = "LOCALE";
             strlcpy(unixname, ret, sizeof(unixname));
         }
         else
@@ -131,7 +108,7 @@ static const char *charset_name(charset_t ch)
     }
     else if (ch == CH_MAC) {
         if (macname[0] == '\0') {
-            ret = read_charsets_from_env(CH_MAC);
+            ret = "MAC_ROMAN";
             strlcpy(macname, ret, sizeof(macname));
         }
         else