X-Git-Url: https://diplodocus.org/git/nmh/blobdiff_plain/1691e80890e5d8ba258c51c214a3e91880e1db2b..e458e7d100c31d7229d376272f90ef93052ff43f:/uip/rcvtty.c diff --git a/uip/rcvtty.c b/uip/rcvtty.c index 9eb365f1..cb194dd5 100644 --- a/uip/rcvtty.c +++ b/uip/rcvtty.c @@ -189,7 +189,11 @@ message_fd (char **vec) char tmpfil[BUFSIZ]; struct stat st; +#ifdef HAVE_MKSTEMP + unlink (mkstemp (strncpy (tmpfil, "/tmp/rcvttyXXXXX", sizeof(tmpfil)))); +#else unlink (mktemp (strncpy (tmpfil, "/tmp/rcvttyXXXXX", sizeof(tmpfil)))); +#endif if ((fd = open (tmpfil, O_RDWR | O_CREAT | O_TRUNC, 0600)) == NOTOK) return header_fd (); unlink (tmpfil);