Changeset bebd154 in mainline
- Timestamp:
- 2019-05-28T18:38:09Z (6 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 52acfab
- Parents:
- 0d14c25
- git-author:
- Jiří Zárevúcky <zarevucky.jiri@…> (2019-05-28 18:37:57)
- git-committer:
- Jiří Zárevúcky <zarevucky.jiri@…> (2019-05-28 18:38:09)
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
abi/include/limits.h
r0d14c25 rbebd154 84 84 #define MB_LEN_MAX 4 85 85 86 #define __NAME_MAX 25687 88 86 #ifdef _HELENOS_SOURCE 89 87 #define UCHAR_MIN 0 … … 104 102 105 103 #define SSIZE_MAX INTPTR_MAX 106 #define NAME_MAX __NAME_MAX104 #define NAME_MAX 255 107 105 108 106 #endif -
uspace/lib/c/generic/dirent.c
r0d14c25 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; -
uspace/lib/c/include/dirent.h
r0d14c25 rbebd154 36 36 #define _LIBC_DIRENT_H_ 37 37 38 #include <limits.h>39 38 #include <_bits/decls.h> 40 39 … … 42 41 43 42 struct dirent { 44 char d_name[ __NAME_MAX + 1];43 char d_name[256]; 45 44 }; 46 45
Note:
See TracChangeset
for help on using the changeset viewer.