By default, Bugzilla does not search the list of RESOLVED bugs.
You can force it to do so by putting the upper-case word ALL in front of your search query, e.g.: ALL tdelibs
We recommend searching for bugs this way, as you may discover that your bug has already been resolved and fixed in a later release.
Bug 3171 - [khangman] Infinte loop during the loading of the settings
Summary: [khangman] Infinte loop during the loading of the settings
Status: RESOLVED FIXED
Alias: None
Product: TDE
Classification: Unclassified
Component: tdeedu (show other bugs)
Version: R14.0.x [Trinity]
Hardware: amd64 All
: P5 normal
Assignee: Michele Calgaro
URL:
Depends on:
Blocks: R14.0.10
  Show dependency treegraph
 
Reported: 2020-11-11 12:31 CST by L-Sebastien
Modified: 2020-11-29 01:29 CST (History)
2 users (show)

See Also:
Compiler Version:
TDE Version String:
Application Version:
Application Name:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description L-Sebastien 2020-11-11 12:31:33 CST
Infinite loop is present during the loading of the settings when the current language ('fr' here) isn't present from the directory '/opt/trinity/share/apps/khangman/data'. Only 'en' is present.

Code:
=====
// Language //TODO is selectedLanguage necessary??? only used here
    selectedLanguage = Prefs::selectedLanguage();
    if (m_languages.grep(selectedLanguage).isEmpty())
            selectedLanguage = "en";
    changeStatusbar(m_languageNames[m_languages.findIndex(Prefs::selectedLanguage())], IDS_LANG);


Traces:
=======

(gdb) print selectedLanguage
$3 = "fr"

(gdb) print m_languages
$4 = {
  <TQValueList<TQString>> = TQValueList<TQString> = {
    [0] = "en"
  }, <No data fields>}

=> selectedLanguage is not used instead of 'Prefs::selectedLanguage()'.

Versions:
=========
OS: Centos 7.8
Trinity: R14.0.9
Comment 1 Michele Calgaro 2020-11-29 01:29:35 CST
Confirmed and fixed in commit aeb0ed94 (R14.1) and 8ca79ae1 (R14.0).