Skip to content
  • Tails developers's avatar
    Make guess_best_tor_browser_locale() print the exact guessed locale. (Will-fix: #8693) · 67c4a51a
    Tails developers authored
    The rationale is easiest explained with an example: let
    LANG="pt_BR.UTF-8". Tor Browser doesn't have a "pt-BR" or even a "pt"
    langpack, but it does have a "pt-PT" package, which we want to
    use. Firefox is smart enough that it would pick the "pt-PT" package if
    we set the useragent to just "pt", which is what we did before.
    
    However, we also want to modify the langpack we're gonna use (to
    change the browser name) and we'll use the guessed locale for
    that. Since there's no "pt" package, the previous behaviour will fail,
    but it works fine if guess_best_tor_browser_locale() prints the exact
    locale for some langpack it thinks we should use, so let's do that.
    67c4a51a