summaryrefslogtreecommitdiff
path: root/usr.bin
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1997-05-31 08:17:34 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1997-05-31 08:17:34 +0000
commit3379ac2b1142fa272d97dc55e5a819cf47ebcde5 (patch)
tree4179f6e3f24190bb63747c17d4ee7be507a1d382 /usr.bin
parent0004745f4b0dd820750dea47df55573ed4c987d1 (diff)
futimes avoids race; mycroft
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/ar/extract.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/ar/extract.c b/usr.bin/ar/extract.c
index 7861c3356a1..9943633f831 100644
--- a/usr.bin/ar/extract.c
+++ b/usr.bin/ar/extract.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: extract.c,v 1.2 1996/06/26 05:31:20 deraadt Exp $ */
+/* $OpenBSD: extract.c,v 1.3 1997/05/31 08:17:33 deraadt Exp $ */
/* $NetBSD: extract.c,v 1.5 1995/03/26 03:27:53 glass Exp $ */
/*-
@@ -41,7 +41,7 @@
#if 0
static char sccsid[] = "@(#)extract.c 8.3 (Berkeley) 4/2/94";
#else
-static char rcsid[] = "$OpenBSD: extract.c,v 1.2 1996/06/26 05:31:20 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: extract.c,v 1.3 1997/05/31 08:17:33 deraadt Exp $";
#endif
#endif /* not lint */
@@ -116,7 +116,7 @@ extract(argv)
}
if (options & AR_O) {
tv[0].tv_sec = tv[1].tv_sec = chdr.date;
- if (utimes(file, tv)) {
+ if (futimes(tfd, tv)) {
warn("utimes: %s", file);
eval = 1;
}