projects
/
henge
/
webcc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b0f2278
)
use real CLOPEN and CLCLOSE, replaced temp macros
author
ken
<ken@mihrtec.com>
Fri, 21 Oct 2016 17:37:32 +0000
(10:37 -0700)
committer
ken
<ken@mihrtec.com>
Fri, 21 Oct 2016 17:37:32 +0000
(10:37 -0700)
src/apc/scanner.c
patch
|
blob
|
history
diff --git
a/src/apc/scanner.c
b/src/apc/scanner.c
index
86c096e
..
0d51ffe
100644
(file)
--- a/
src/apc/scanner.c
+++ b/
src/apc/scanner.c
@@
-121,8
+121,6
@@
int scanner
#define ERR_DEPTH "Fatal: Maximum directory depth of " $(DL_STACKSIZE) \
" exceeded during directory scan\n"
#define ERR_DL "Fatal: Directory List Stack Corruption %x\n", DL_LEN()
#define ERR_DEPTH "Fatal: Maximum directory depth of " $(DL_STACKSIZE) \
" exceeded during directory scan\n"
#define ERR_DL "Fatal: Directory List Stack Corruption %x\n", DL_LEN()
-#define TOK_CLOPEN 0x55, 1 //TODO
-#define TOK_CLCLOSE 0x56, 1 //TODO
()
{ struct dirent* direntp;
struct DIR* DIRp;
()
{ struct dirent* direntp;
struct DIR* DIRp;
@@
-144,7
+142,7
@@
int scanner
DL_PUSH(opendir(CWDSTR));
if (DL_CURDIR() == NULL) //open the cwd
goto libfail;
DL_PUSH(opendir(CWDSTR));
if (DL_CURDIR() == NULL) //open the cwd
goto libfail;
- lexer_pushtok(
TOK_CLOPEN);
//Push "Open Directory" token
+ lexer_pushtok(
CLOPEN, 0);
//Push "Open Directory" token
return dredge_current_depth(); //Filter and sort the current depth
}
else if (DL_LEN() >= 0) //Any dirs left? (Including root)
return dredge_current_depth(); //Filter and sort the current depth
}
else if (DL_LEN() >= 0) //Any dirs left? (Including root)
@@
-152,7
+150,7
@@
int scanner
goto libfail;
if (DL_LEN() == -1) //If we just popped root,
return 0; //we're done
goto libfail;
if (DL_LEN() == -1) //If we just popped root,
return 0; //we're done
- lexer_pushtok(
TOK_CLCLOSE);
//Else push "Close Directory" token,
+ lexer_pushtok(
CLCLOSE, 0);
//Else push "Close Directory" token,
if (!chdir("..")) //move up a directory and
goto parse; //start over
}
if (!chdir("..")) //move up a directory and
goto parse; //start over
}