fix !appendfile writing null bytes on linux and breaking LogicLib ${Switch} statements
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@6738 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
7a958101d8
commit
d5662388a3
1 changed files with 3 additions and 3 deletions
|
@ -130,9 +130,9 @@ size_t CharEncConv::GuessOutputSize(size_t cbConverted)
|
||||||
if (!cch) return 0;
|
if (!cch) return 0;
|
||||||
switch(cus)
|
switch(cus)
|
||||||
{
|
{
|
||||||
case 1: zt = !!((char*)m_Result)[--cch]; break;
|
case 1: zt = !((char*)m_Result)[--cch]; break;
|
||||||
case 2: zt = !!((WORD*)m_Result)[--cch]; break;
|
case 2: zt = !((WORD*)m_Result)[--cch]; break;
|
||||||
case 4: zt = !!((UINT32*)m_Result)[--cch]; break;
|
case 4: zt = !((UINT32*)m_Result)[--cch]; break;
|
||||||
}
|
}
|
||||||
return (cch + (zt ? 0 : 1)) * cus;
|
return (cch + (zt ? 0 : 1)) * cus;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue