FIRE-29649: Crash when opening spellcheck settings

meow-7.2.2
Ansariel 2020-06-01 16:31:27 +02:00
parent ae38de8871
commit 21809adba0
2 changed files with 10 additions and 1 deletions

View File

@ -50,7 +50,7 @@ LLSpellChecker::LLSpellChecker()
: mHunspell(NULL)
{
// Load initial dictionary information
refreshDictionaryMap();
//refreshDictionaryMap(); // <FS:Ansariel> FIRE-29649: Crash when opening spellcheck settings
}
LLSpellChecker::~LLSpellChecker()
@ -58,6 +58,14 @@ LLSpellChecker::~LLSpellChecker()
delete mHunspell;
}
// <FS:Ansariel> FIRE-29649: Crash when opening spellcheck settings
void LLSpellChecker::initSingleton()
{
// Load initial dictionary information
refreshDictionaryMap();
}
// </FS:Ansariel>
bool LLSpellChecker::checkSpelling(const std::string& word) const
{
if ( (!mHunspell) || (word.length() < 3) || (0 != mHunspell->spell(word.c_str())) )

View File

@ -47,6 +47,7 @@ public:
protected:
void addToDictFile(const std::string& dict_path, const std::string& word);
void initHunspell(const std::string& dict_language);
void initSingleton(); // <FS:Ansariel> FIRE-29649: Crash when opening spellcheck settings
public:
typedef std::list<std::string> dict_list_t;