Changes in uspace/lib/c/generic/dirent.c [391996b:bebd154] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/dirent.c
r391996b rbebd154 39 39 #include <errno.h> 40 40 #include <assert.h> 41 #include <string.h> 41 42 42 43 struct __dirstream { … … 92 93 ssize_t len = 0; 93 94 94 rc = vfs_read_short(dirp->fd, dirp->pos, &dirp->res.d_name[0],95 NAME_MAX + 1, &len);95 rc = vfs_read_short(dirp->fd, dirp->pos, dirp->res.d_name, 96 sizeof(dirp->res.d_name), &len); 96 97 if (rc != EOK) { 97 98 errno = rc; 98 99 return NULL; 99 100 } 101 102 assert(strnlen(dirp->res.d_name, sizeof(dirp->res.d_name)) < sizeof(dirp->res.d_name)); 100 103 101 104 dirp->pos += len;
Note:
See TracChangeset
for help on using the changeset viewer.