I18n: tweak/fix exception catching code of pgettex() wrapper.
Related to T57066, rather unlikely to fix core of the issue, but may solve crash itself.
This commit is contained in:
parent
1ab08a2dff
commit
f22385f28e
Notes:
blender-bot
2023-02-14 09:38:57 +01:00
Referenced by commit 35d7211bfa
, I18n: tweak/fix exception catching code of pgettex() wrapper.
Referenced by issue #57359, Crash adding a Driver and then changing frame.
Referenced by issue #57360, 2.8 - Crash when Play Animation in this scene
|
@ -112,13 +112,17 @@ const char *bl_locale_pgettext(const char *msgctxt, const char *msgid)
|
|||
return r;
|
||||
return msgid;
|
||||
}
|
||||
catch(std::bad_cast const &e) { /* if std::has_facet<char_message_facet>(l) == false, LC_ALL = "C" case */
|
||||
// std::cout << "bl_locale_pgettext(" << msgid << "): " << e.what() << " \n";
|
||||
catch(const std::bad_cast &e) { /* if std::has_facet<char_message_facet>(l) == false, LC_ALL = "C" case */
|
||||
#ifndef NDEBUG
|
||||
std::cout << "bl_locale_pgettext(" << msgctxt << ", " << msgid << "): " << e.what() << " \n";
|
||||
#endif
|
||||
(void)e;
|
||||
return msgid;
|
||||
}
|
||||
catch(std::exception const &e) {
|
||||
// std::cout << "bl_locale_pgettext(" << msgctxt << ", " << msgid << "): " << e.what() << " \n";
|
||||
catch(const std::exception &e) {
|
||||
#ifndef NDEBUG
|
||||
std::cout << "bl_locale_pgettext(" << msgctxt << ", " << msgid << "): " << e.what() << " \n";
|
||||
#endif
|
||||
(void)e;
|
||||
return msgid;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue