Prevent crash when using an unknown locale (#692049)
When GParted is run with a locale the OS doesn't know it crashes. Reapply original fix. # LANG=xx_XX.UTF-8 ~mike/bin/gpartedbin (process:20385): Gtk-WARNING **: Locale not supported by C library. Using the fallback 'C' locale. ====================== libparted : 3.1 ====================== (gpartedbin:20385): glibmm-ERROR **: unhandled exception (type std::exception) in signal handler: what: locale::facet::_S_create_c_locale name not valid Trace/breakpoint trap (core dumped) Original bug: Bug #157871 - gparted 0.0.6 segfaults on start First fix: commita98126d69b
quick 'fix' for crashers in some locales (#157871) basicly the same + Accidentally reintroduced by: commita739afc9a1
Update String::ucompose library to version 1.0.5 Bug #692049 - Troubles with some locales
This commit is contained in:
parent
90337f157a
commit
75eba94a6c
|
@ -186,7 +186,8 @@ namespace UStringPrivate
|
|||
: arg_no(1)
|
||||
{
|
||||
#if __GNUC__ >= 3
|
||||
os.imbue(std::locale("")); // use the user's locale for the stream
|
||||
//Prevent crash with unknown locales. See bugs #157871, #692049
|
||||
//os.imbue(std::locale("")); // use the user's locale for the stream
|
||||
#endif
|
||||
std::string::size_type b = 0, i = 0;
|
||||
|
||||
|
|
Loading…
Reference in New Issue