Stop at the first error.

This commit is contained in:
nekral-guest 2007-12-28 00:08:16 +00:00
parent ed1dd1bb99
commit 523392dc0b

View File

@ -217,7 +217,7 @@ int copy_tree (const char *src_root, const char *dst_root, uid_t uid, gid_t gid)
dst_orig = dst_root;
set_orig++;
}
while ((ent = readdir (dir))) {
while ((0 == err) && (ent = readdir (dir)) != NULL) {
/*
* Skip the "." and ".." entries