Allow CP_ACP as the codepage in NLF files even if IsValidCodePage() says no

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@6301 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
anders_k 2013-03-14 22:27:48 +00:00
parent 7e6db0aa39
commit 2fc40abca0

View file

@ -1019,9 +1019,9 @@ l_readerr:
if (!GetNextNLFLine(lr, buf, NSIS_MAX_STRLEN, errlr)) goto l_readerr;
if (buf[0] != _T('-') || buf[1] != 0) {
nlf->m_uCodePage = _ttoi(buf);
if (!IsValidCodePage(nlf->m_uCodePage))
if (!IsValidCodePage(nlf->m_uCodePage) && CP_ACP != nlf->m_uCodePage)
{
warning_fl(_T("%s language file uses a codepage that is not supported on this system, using ACP!"), nlf->m_szName);
warning_fl(_T("%s language file uses a codepage (%d) that is not supported on this system, using ACP!"), nlf->m_szName, nlf->m_uCodePage);
nlf->m_uCodePage = CP_ACP;
}
}