Index: /libmpc/branches/r2d/mpcenc/config.h
===================================================================
--- /libmpc/branches/r2d/mpcenc/config.h	(revision 271)
+++ /libmpc/branches/r2d/mpcenc/config.h	(revision 272)
@@ -32,6 +32,6 @@
 
 #define MPCENC_MAJOR 1
-#define MPCENC_MINOR 19
-#define MPCENC_BUILD 1
+#define MPCENC_MINOR 21
+#define MPCENC_BUILD 0
 
 /* end of config.h */
Index: /libmpc/branches/r2d/mpcenc/mpcenc.c
===================================================================
--- /libmpc/branches/r2d/mpcenc/mpcenc.c	(revision 271)
+++ /libmpc/branches/r2d/mpcenc/mpcenc.c	(revision 272)
@@ -232,5 +232,6 @@
              "                   ean/upc, year, releasedate, genre, media, index, isrc,\n"
              "                   abstract, bibliography, introplay, media, language, ...\n"
-             "  --unicode        unicode input from console\n"
+			 "  --unicode        Toggle unicode input from console on/off if autodetection\n"
+			 "                   doesn't work. This switch MUST be before any tag switch.\n"
              "\n" );
 
@@ -1041,5 +1042,5 @@
         }
         else if ( 0 == strcmp ( arg, "unicode") ) {                                  // no tag conversion
-            NoUnicode = 0;
+            NoUnicode = 1 - NoUnicode;
 		}
 		else if ( 0 == strcmp ( arg, "no_ei") ) {                                  // no encoder info block
@@ -1798,4 +1799,9 @@
 #endif
 
+#ifdef LC_CTYPE
+	setlocale(LC_CTYPE, "");
+	NoUnicode = (strcmp(nl_langinfo(CODESET), "UTF-8") != 0);
+#endif
+
     if ( WIN32_MESSAGES ) {
         FrontendPresent = SearchForFrontend (); // search for presence of Windows Frontend
Index: /libmpc/branches/r2d/mpcenc/mpcenc.h
===================================================================
--- /libmpc/branches/r2d/mpcenc/mpcenc.h	(revision 271)
+++ /libmpc/branches/r2d/mpcenc/mpcenc.h	(revision 272)
@@ -43,4 +43,6 @@
 #elif defined __unix__  ||  defined __linux__  ||  defined __APPLE__
 # include <unistd.h>
+# include <locale.h>
+# include <langinfo.h>
 #else
 // .... add Includes for new Operating System here (with prefix: #elif defined)
