summaryrefslogtreecommitdiff
path: root/bin/cp/utils.c
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1998-06-07 05:16:35 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1998-06-07 05:16:35 +0000
commit333ef11cb24bbfa6517989d357ca61c5e76ac75b (patch)
treee0d238334f7875a34131d609fee2a3ce6f49b4be /bin/cp/utils.c
parenta13a4b22d9f8a54490b77788dba5cef2a5e1337e (diff)
use MAP_FAILED
Diffstat (limited to 'bin/cp/utils.c')
-rw-r--r--bin/cp/utils.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/bin/cp/utils.c b/bin/cp/utils.c
index 9a9a18b79ce..185eeef260c 100644
--- a/bin/cp/utils.c
+++ b/bin/cp/utils.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: utils.c,v 1.11 1998/05/18 09:58:05 deraadt Exp $ */
+/* $OpenBSD: utils.c,v 1.12 1998/06/07 05:16:34 deraadt Exp $ */
/* $NetBSD: utils.c,v 1.6 1997/02/26 14:40:51 cgd Exp $ */
/*-
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)utils.c 8.3 (Berkeley) 4/1/94";
#else
-static char rcsid[] = "$OpenBSD: utils.c,v 1.11 1998/05/18 09:58:05 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: utils.c,v 1.12 1998/06/07 05:16:34 deraadt Exp $";
#endif
#endif /* not lint */
@@ -117,7 +117,7 @@ copy_file(entp, dne)
#ifdef VM_AND_BUFFER_CACHE_SYNCHRONIZED
if (fs->st_size <= 8 * 1048576) {
if ((p = mmap(NULL, (size_t)fs->st_size, PROT_READ,
- 0, from_fd, (off_t)0)) == (char *)-1) {
+ 0, from_fd, (off_t)0)) == MAP_FAILED) {
warn("mmap: %s", entp->fts_path);
rval = 1;
} else {