aboutsummaryrefslogtreecommitdiff
path: root/toys/cp.c
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2008-12-14 01:08:37 -0600
committerRob Landley <rob@landley.net>2008-12-14 01:08:37 -0600
commit7471b5618cb5bee9cc5daaf26cc5d69770b4cb17 (patch)
treee1b0d989e2a0994c807a08a4ef1367705609635b /toys/cp.c
parentdcb52f7c9a01a0609a7d4f00256f6807ae49320b (diff)
downloadtoybox-7471b5618cb5bee9cc5daaf26cc5d69770b4cb17.tar.gz
Shut up some new aggressively stupid warnings gcc 4.3 produces.
Diffstat (limited to 'toys/cp.c')
-rw-r--r--toys/cp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/toys/cp.c b/toys/cp.c
index 04c6369b..3aaa00fb 100644
--- a/toys/cp.c
+++ b/toys/cp.c
@@ -109,10 +109,10 @@ void cp_file(char *src, char *dst, struct stat *srcst)
// Can't do fchmod() etc here because -p works on mkdir, too.
if (toys.optflags & FLAG_p) {
- int mask = umask(0);
+ int mask = umask(0), ignored;
struct utimbuf ut;
- fchown(fdout,srcst->st_uid, srcst->st_gid);
+ ignored = fchown(fdout,srcst->st_uid, srcst->st_gid);
ut.actime = srcst->st_atime;
ut.modtime = srcst->st_mtime;
utime(dst, &ut);