Reduce memory usage in low level tree, by storing dir info separately.

This commit is contained in:
Vreixo Formoso
2007-12-29 18:30:59 +01:00
parent 4b8db2f274
commit 7e66fe43ce
6 changed files with 76 additions and 60 deletions

View File

@ -51,8 +51,8 @@ print_dir(Ecma119Node *dir, int level)
sp[level * 2-1] = '-';
sp[level * 2] = '\0';
for (i = 0; i < dir->info.dir.nchildren; i++) {
Ecma119Node *child = dir->info.dir.children[i];
for (i = 0; i < dir->info.dir->nchildren; i++) {
Ecma119Node *child = dir->info.dir->children[i];
if (child->type == ECMA119_DIR) {
printf("%s+[D] ", sp);