diff options
Diffstat (limited to 'libc/sysdeps/linux/common/getdents64.c')
-rw-r--r-- | libc/sysdeps/linux/common/getdents64.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libc/sysdeps/linux/common/getdents64.c b/libc/sysdeps/linux/common/getdents64.c index e45d9d364..37ecc1339 100644 --- a/libc/sysdeps/linux/common/getdents64.c +++ b/libc/sysdeps/linux/common/getdents64.c @@ -95,7 +95,7 @@ ssize_t attribute_hidden __getdents64 (int fd, char *buf, size_t nbytes) dp->d_off = kdp->d_off; dp->d_reclen = new_reclen; dp->d_type = DT_UNKNOWN; - memcpy (dp->d_name, kdp->d_name, + __memcpy (dp->d_name, kdp->d_name, kdp->d_reclen - offsetof (struct kernel_dirent64, d_name)); dp = (struct dirent64 *) ((char *) dp + new_reclen); kdp = (struct kernel_dirent64 *) (((char *) kdp) + kdp->d_reclen); |