Commit Diff
Commit:
b5fdc32e758f57a11fcb78a7571649044b681b1b
From:
Omar Polo <op@omarpolo.com>
Date:
Sun Apr 25 12:49:21 2021 UTC
Message:
use memcpy instead of bcopy memcpy is ANSI C89, bcopy seems to be an history BSD function.
commit - 5aba63956a04590ade71cffa0cef0a5d2356f42b
commit + b5fdc32e758f57a11fcb78a7571649044b681b1b
blob - 66e38d490f89e16da1b669a2510e5edb366353f9
blob + 3b447e5e4d8358c317cc39ab56e0923d7db8fa04
--- dirs.c
+++ dirs.c
@@ -129,7 +129,7 @@ scandir_fd(int fd, struct dirent ***namelist,
p->d_ino = d->d_ino;
p->d_type = d->d_type;
p->d_reclen = d->d_reclen;
- bcopy(d->d_name, p->d_name, namlen + 1);
+ memcpy(p->d_name, d->d_name, namlen + 1);
names[nitems++] = p;
}
closedir(dirp);
Omar Polo