Lines Matching refs:node
48 struct dirtree *node;
53 static void print(long long size, struct dirtree *node)
70 if (node) name = dirtree_path(node, NULL);
72 if (node) free(name);
106 // dirtree callback, comput/display size of node
107 static int do_du(struct dirtree *node)
109 if (!node->parent) TT.st_dev = node->st.st_dev;
110 else if (!dirtree_notdotdot(node)) return 0;
113 if ((toys.optflags & FLAG_x) && (TT.st_dev != node->st.st_dev))
118 struct dirtree *try = node;
121 if (node->st.st_dev==try->st.st_dev && node->st.st_ino==try->st.st_ino)
126 if (!(toys.optflags & FLAG_l) && !node->again)
127 if (seen_inode(&TT.inodes, &node->st)) return 0;
130 if (S_ISDIR(node->st.st_mode)) {
131 if (!node->again) {
137 node->extra += node->st.st_blocks;
138 if (node->parent) node->parent->extra += node->extra;
139 else TT.total += node->extra;
141 if ((toys.optflags & FLAG_a) || !node->parent
142 || (S_ISDIR(node->st.st_mode) && !(toys.optflags & FLAG_s)))
144 print(node->extra*512, node);