Changeset 736c164 in mainline for uspace/lib/libfs/libfs.c
- Timestamp:
- 2008-03-30T22:30:32Z (17 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 94b0b63
- Parents:
- 81c0171e
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/libfs/libfs.c
r81c0171e r736c164 149 149 void *par = NULL; 150 150 void *cur = ops->root_get(); 151 void *tmp = ops->child_get(cur);151 void *tmp; 152 152 153 153 if (ops->plb_get_char(next) == '/') … … 156 156 char component[NAME_MAX + 1]; 157 157 int len = 0; 158 while ( tmp&& next <= last) {158 while (ops->has_children(cur) && next <= last) { 159 159 160 160 /* collect the component */ … … 177 177 178 178 /* match the component */ 179 while (tmp && !ops->match(cur, tmp, component)) 180 tmp = ops->sibling_get(tmp); 179 tmp = ops->match(cur, component); 181 180 182 181 /* handle miss: match amongst siblings */ … … 229 228 par = cur; 230 229 cur = tmp; 231 tmp = ops->child_get(tmp);232 230 } 233 231 234 232 /* handle miss: excessive components */ 235 if (! tmp&& next <= last) {233 if (!ops->has_children(cur) && next <= last) { 236 234 if (lflag & (L_CREATE | L_LINK)) { 237 235 if (!ops->is_directory(cur)) {
Note:
See TracChangeset
for help on using the changeset viewer.