!macroend was only being recognised at the beginning of a line
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@1287 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
806e0bc3da
commit
97c3fb52bf
1 changed files with 8 additions and 7 deletions
|
@ -425,7 +425,8 @@ int CEXEBuild::doCommand(int which_token, LineParser &line, FILE *fp, const char
|
|||
if (p > str) p--;
|
||||
while (p >= str && (*p == '\r' || *p == '\n' || *p == ' ' || *p == '\t')) p--;
|
||||
*++p=0;
|
||||
if (!strnicmp(str,"!macroend",sizeof("!macroend"))) break;
|
||||
LineParser l2;
|
||||
if (!l2.parse(str) && !stricmp(l2.gettoken_str(0),"!macroend")) break;
|
||||
if (str[0]) m_macros.add(str,strlen(str)+1);
|
||||
else m_macros.add(" ",2);
|
||||
}
|
||||
|
@ -2310,27 +2311,27 @@ int CEXEBuild::doCommand(int which_token, LineParser &line, FILE *fp, const char
|
|||
SCRIPT_MSG("(->%s)",line.gettoken_str(5));
|
||||
a++;
|
||||
}
|
||||
|
||||
|
||||
if (!strncmp(line.gettoken_str(a),"/TIMEOUT=",9))
|
||||
{
|
||||
ent.offsets[5]|=atoi(line.gettoken_str(a)+9)<<2;
|
||||
SCRIPT_MSG(" (timeout=%d)",ent.offsets[5]>>2);
|
||||
a++;
|
||||
}
|
||||
|
||||
if (line.getnumtokens()>a)
|
||||
|
||||
if (line.getnumtokens()>a)
|
||||
{
|
||||
PRINTHELP()
|
||||
}
|
||||
}
|
||||
|
||||
if (!strncmp(line.gettoken_str(3),"STR:",4))
|
||||
if (!strncmp(line.gettoken_str(3),"STR:",4))
|
||||
{
|
||||
ent.offsets[5]|=1;
|
||||
ent.offsets[3]=add_string(line.gettoken_str(3)+4);
|
||||
}
|
||||
else ent.offsets[3]=add_string(line.gettoken_str(3));
|
||||
if (!strncmp(line.gettoken_str(4),"STR:",4))
|
||||
if (!strncmp(line.gettoken_str(4),"STR:",4))
|
||||
{
|
||||
ent.offsets[5]|=2;
|
||||
ent.offsets[4]=add_string(line.gettoken_str(4)+4);
|
||||
|
@ -3874,4 +3875,4 @@ int CEXEBuild::do_add_file(const char *lgss, int attrib, int recurse, int linecn
|
|||
}
|
||||
return PS_OK;
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue