Re: Unicode or not?
Andrej Gelenberg <[email protected]> Mon, 05 Mar 2012 15:04:18 +0100
| Newsgroups | org.kernel.vger.linux-c-programming |
|---|---|
| Message-ID | <[email protected]> |
HI, it's always char **, which encoding the arguments has, depends on system locale (mostly LANG environment variable), but it must be always some sort of multibyte encoding at most (like utf8). UCS 2 (UTF-16) would break many existing programs. http://stackoverflow.com/questions/1664476/is-it-possible-to-use-a-unicode-argv and here, how to covert between utf8 and wchar: http://www.ibm.com/developerworks/linux/library/l-linuni/index.html On 03/05/2012 01:23 PM, Krzysztof wrote: > Does it happen that command line which is passed to program arguments is > "unicoded"? In other words, when should "main" be defined as "main(int > argc, wchar_t **argv)"? > Regards, Andrej Gelenberg