summaryrefslogtreecommitdiff
path: root/usr.bin/window/wwterminfo.c
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>1999-11-14 17:34:25 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>1999-11-14 17:34:25 +0000
commit24c993d46ca2f888f6be6baf256bab1d17bdffa0 (patch)
treee26f0f93dd5cd7dc09fec09407622a1ba0708348 /usr.bin/window/wwterminfo.c
parentbc8cbbd687d0349dcd8509123625f8e894087662 (diff)
o link with -ocurses for now since window does not work properly with ncurses
o use mkdtemp(), not mktemp + mkdir in TERMINFO support o correct program paths for TERMINFO support o use the curses unctrl() function instead of a private one
Diffstat (limited to 'usr.bin/window/wwterminfo.c')
-rw-r--r--usr.bin/window/wwterminfo.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/usr.bin/window/wwterminfo.c b/usr.bin/window/wwterminfo.c
index 6b3b0694762..556d7811948 100644
--- a/usr.bin/window/wwterminfo.c
+++ b/usr.bin/window/wwterminfo.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wwterminfo.c,v 1.7 1998/03/17 04:11:55 deraadt Exp $ */
+/* $OpenBSD: wwterminfo.c,v 1.8 1999/11/14 17:34:24 millert Exp $ */
/*
* Copyright (c) 1982, 1993
@@ -40,7 +40,7 @@
#if 0
static char sccsid[] = "@(#)wwterminfo.c 8.1 (Berkeley) 6/6/93";
#else
-static char rcsid[] = "$OpenBSD: wwterminfo.c,v 1.7 1998/03/17 04:11:55 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: wwterminfo.c,v 1.8 1999/11/14 17:34:24 millert Exp $";
#endif
#endif /* not lint */
@@ -69,10 +69,8 @@ wwterminfoinit()
/* make the directory */
(void) snprintf(wwterminfopath, sizeof wwterminfopath,
- "%swwinXXXXXX", _PATH_TMP);
- mktemp(wwterminfopath);
- if (mkdir(wwterminfopath, 0755) < 0 ||
- chmod(wwterminfopath, 00755) < 0) {
+ "%swwinXXXXXXXXXX", _PATH_TMP);
+ if (mkdtemp(wwterminfopath) == NULL) {
wwerrno = WWE_SYS;
return -1;
}