summaryrefslogtreecommitdiffstats
path: root/cpukit
diff options
context:
space:
mode:
Diffstat (limited to 'cpukit')
-rw-r--r--cpukit/libcsupport/src/scandir.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/cpukit/libcsupport/src/scandir.c b/cpukit/libcsupport/src/scandir.c
index 25f3263187..43c7c51747 100644
--- a/cpukit/libcsupport/src/scandir.c
+++ b/cpukit/libcsupport/src/scandir.c
@@ -112,7 +112,7 @@ scandir(dirname, namelist, select, dcomp)
p->d_ino = d->d_ino;
p->d_reclen = d->d_reclen;
p->d_namlen = d->d_namlen;
- strncpy(d->d_name, p->d_name, p->d_namlen + 1);
+ strncpy(p->d_name, d->d_name, p->d_namlen + 1);
/*
* Check to make sure the array has space left and
* realloc the maximum size.