]> git.marmaro.de Git - mmh/blobdiff - uip/rcvtty.c
configure, configure.in stamp-h.in, and uip/Makefile.in modified to fix
[mmh] / uip / rcvtty.c
index b847b563972e4f0aab765add41c924fe3e0fc581..464a0276be02936d3025fceb9342ef10d0ac4ba0 100644 (file)
@@ -191,13 +191,13 @@ message_fd (char **vec)
     struct stat st;
 
 #ifdef HAVE_MKSTEMP
-    unlink (mkstemp (strncpy (tmpfil, "/tmp/rcvttyXXXXX", sizeof(tmpfil))));
+    fd = 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);
+#endif
 
     if ((child_id = vfork()) == NOTOK) {
        /* fork error */