qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] QEMU produces invalid JSON due to locale-dependent code


From: Markus Armbruster
Subject: Re: [Qemu-devel] QEMU produces invalid JSON due to locale-dependent code
Date: Tue, 25 Aug 2015 14:51:44 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

Alberto Garcia <address@hidden> writes:

> On Tue 25 Aug 2015 09:54:42 AM CEST, Markus Armbruster wrote:
>
>> Switching back to C locale whenever some unwanted locale-dependency
>> breaks the code is problematic, because it involves finding all the
>> places that break, iteratively (euphemism for "we debug one breakage
>> after the other, adding temporary locale switches as we go).
>>
>> I'd feel much better about confining GTK in its own thread, and
>> setting only that thread's locale.
>
> FWIW GTK+ is not thread safe, all GTK+ code must run in the same thread,
> so that should already be happening. I assume however that it's the same
> thread that runs the monitor, so that might not be a solution in the
> end.

If we use thread-local locale for the GTK UI, then anything running in
that thread must either not depend on locale, or be properly
internationalized.  Neither holds for the monitor (or pretty much any
non-trivial part of QEMU).

Can we give the GTK UI code its very own thread?



reply via email to

[Prev in Thread] Current Thread [Next in Thread]