Author: tkreuzer
Date: Fri Oct 3 20:11:37 2014
New Revision: 64514
URL:
http://svn.reactos.org/svn/reactos?rev=64514&view=rev
Log:
[HPP]
Fix problem with inconsistent EOLs
Modified:
trunk/reactos/tools/hpp/hpp.c
Modified: trunk/reactos/tools/hpp/hpp.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/hpp/hpp.c?rev=64514&…
==============================================================================
--- trunk/reactos/tools/hpp/hpp.c [iso-8859-1] (original)
+++ trunk/reactos/tools/hpp/hpp.c [iso-8859-1] Fri Oct 3 20:11:37 2014
@@ -210,11 +210,14 @@
pchVariable = strchr(pch, '$');
if (pchVariable && (pchVariable < pchLineEnd))
{
+ /* Write all characters up to the $ */
fwrite(pch, 1, pchVariable - pch, fileOut);
+ /* Try to find the define */
pDefine = FindDefine(pchVariable + 1, &pch);
if (pDefine != 0)
{
+ /* We have a define, write the value */
fwrite(pDefine->pszValue, 1, pDefine->cchValue, fileOut);
}
else
@@ -224,7 +227,7 @@
fwrite(pchVariable, 1, pch - pchVariable, fileOut);
}
- len = pchLineEnd - pch;
+ len = pchLineEnd - pch + 1;
}
else
{