develooper Front page | perl.perl5.porters | Postings from September 2003

[PATCH 5.8.1 @21211] tmpfile() broken on OS/2

Thread Next
From:
Ilya Zakharevich
Date:
September 25, 2003 12:07
Subject:
[PATCH 5.8.1 @21211] tmpfile() broken on OS/2
Message ID:
20030925190722.GA27017@math.berkeley.edu
This patch is not complete.  An additional discipline is needed to
unlink on close().  But at least it improves things w.r.t. using
mkstemp() on "/tmp/foo": files are created in a suitable directory,
and their number is not restricted to 26.

Thanks,
Ilya

--- ./perlio.c-pre	Sat Sep 13 10:26:32 2003
+++ ./perlio.c	Sat Sep 20 00:07:48 2003
@@ -4861,7 +4861,7 @@ PerlIO_tmpfile(void)
      if (fd >= 0)
 	  f = PerlIO_fdopen(fd, "w+b");
 #else /* WIN32 */
-#    ifdef HAS_MKSTEMP
+#    if defined(HAS_MKSTEMP) && !defined(OS2)
      SV *sv = newSVpv("/tmp/PerlIO_XXXXXX", 0);
 
      /*

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About