# HG changeset patch # User Rob Landley # Date 1229238517 21600 # Node ID 6773399539aa9a027486782ce05db2f22913e23b # Parent 48e0f1f45181f880197dad030469e227d3ecd84c Shut up some new aggressively stupid warnings gcc 4.3 produces. diff -r 48e0f1f45181 -r 6773399539aa toys/cp.c --- a/toys/cp.c Mon Dec 08 00:16:07 2008 -0600 +++ b/toys/cp.c Sun Dec 14 01:08:37 2008 -0600 @@ -109,10 +109,10 @@ // 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); diff -r 48e0f1f45181 -r 6773399539aa toys/mdev.c --- a/toys/mdev.c Mon Dec 08 00:16:07 2008 -0600 +++ b/toys/mdev.c Sun Dec 14 01:08:37 2008 -0600 @@ -168,7 +168,9 @@ if (mknod(temp, mode | type, makedev(major, minor)) && errno != EEXIST) perror_exit("mknod %s failed", temp); - if (CFG_MDEV_CONF) chown(temp, uid, gid); + // Dear gcc: shut up about ignoring the return value here. If it doesn't + // work, what exactly are we supposed to do about it? + if (CFG_MDEV_CONF) mode=chown(temp, uid, gid); } static int callback(char *path, struct dirtree *node)