No more static variables in CEXEBuild member functions
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@2849 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
4dc04a8e5d
commit
9cd28a4c3d
3 changed files with 7 additions and 11 deletions
|
@ -140,15 +140,12 @@ class CEXEBuild {
|
|||
} *cur_ifblock;
|
||||
|
||||
TinyGrowBuf build_preprocessor_data;
|
||||
int last_line_had_slash;
|
||||
|
||||
void start_ifblock();
|
||||
void end_ifblock();
|
||||
int num_ifblock();
|
||||
/*int ignore;
|
||||
int if_count;
|
||||
int ignored_if_count;
|
||||
int wait_for_endif;*/
|
||||
|
||||
int last_line_had_slash;
|
||||
bool inside_comment;
|
||||
|
||||
void ERROR_MSG(const char *s, ...);
|
||||
|
@ -282,6 +279,8 @@ class CEXEBuild {
|
|||
|
||||
char build_output_filename[1024];
|
||||
|
||||
int build_include_depth;
|
||||
|
||||
// Added by ramon 6 jun 2003
|
||||
#ifdef NSIS_SUPPORT_VERSION_INFO
|
||||
CResourceVersionInfo rVersionInfo;
|
||||
|
|
|
@ -2431,14 +2431,13 @@ int CEXEBuild::doCommand(int which_token, LineParser &line)
|
|||
if (malloced) free(f);
|
||||
return PS_ERROR;
|
||||
}
|
||||
static int depth;
|
||||
if (depth >= MAX_INCLUDEDEPTH)
|
||||
if (build_include_depth >= MAX_INCLUDEDEPTH)
|
||||
{
|
||||
ERROR_MSG("parseScript: too many levels of includes (%d max).\n",MAX_INCLUDEDEPTH);
|
||||
if (malloced) free(f);
|
||||
return PS_ERROR;
|
||||
}
|
||||
depth++;
|
||||
build_include_depth++;
|
||||
|
||||
int last_linecnt=linecnt;
|
||||
linecnt=0;
|
||||
|
@ -2468,7 +2467,7 @@ int CEXEBuild::doCommand(int which_token, LineParser &line)
|
|||
curfilename=last_filename;
|
||||
fp=last_fp;
|
||||
|
||||
depth--;
|
||||
build_include_depth--;
|
||||
fclose(incfp);
|
||||
if (r != PS_EOF && r != PS_OK)
|
||||
{
|
||||
|
|
2
TODO.txt
2
TODO.txt
|
@ -16,8 +16,6 @@ NSIS
|
|||
|
||||
* LZMA compression
|
||||
|
||||
* stop using static variables so CEXEBuild can be used as a real class
|
||||
|
||||
EXAMPLES
|
||||
|
||||
* write an advanced paging example showing multiple components page with multiple
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue