[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: setlocale doesn't change the language. Why?



On Wed, Mar 11, 2015 at 01:27:21PM +0000, Joerg Desch wrote:
> Switch to 'en'
> New LOCALE: 'C'
> Hello World
> Switch to 'de'
> New LOCALE: 'C'
> Hello World
So these cases are expected to you?

> Switch to 'de.utf8'
> New LOCALE: 'de_DE.UTF8'
> Hallo Welt
> 
> And on the embedded PC:
> # ./sample2
> Current LOCALE: 'C'
> Switch to 'en'
> New LOCALE: 'C'
> Hello World
> Switch to 'de'
> New LOCALE: 'C'
> Hello World
> Switch to 'de.utf8'
> New LOCALE: 'C'
> Hello World
You don't have 'de.utf8' locale on this system.
setlocale(3) has a return value which you should check if you are
interested whether it succeeded.

-- 
WBR, wRAR

Attachment: signature.asc
Description: Digital signature


Reply to: