httpd-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From r..@locus.apache.org
Subject cvs commit: apache-2.0/src/lib/apr/locks/unix locks.c locks.h
Date Sat, 03 Jun 2000 00:31:15 GMT
rbb         00/06/02 17:31:15

  Modified:    src/lib/apr/locks/unix locks.c locks.h
  Log:
  FreeBSD 4.0 doesn't like tempnam, so we are using mkstemp now.  I hope
  this works on all platforms, but if not we'll just use a #ifdef later.
  
  Revision  Changes    Path
  1.32      +3 -1      apache-2.0/src/lib/apr/locks/unix/locks.c
  
  Index: locks.c
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/lib/apr/locks/unix/locks.c,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- locks.c	2000/04/30 21:17:56	1.31
  +++ locks.c	2000/06/03 00:31:13	1.32
  @@ -74,7 +74,9 @@
               new->fname = ap_pstrdup(cont, fname);
           }
           else {
  -            new->fname = ap_pstrdup(cont, tempnam(NULL, NULL));
  +            char *filename = "/tmp/aprXXXXXX";
  +            new->interproc = mkstemp(filename);
  +            new->fname = ap_pstrdup(cont, filename); 
               unlink(new->fname);
   	}
       }
  
  
  
  1.21      +3 -0      apache-2.0/src/lib/apr/locks/unix/locks.h
  
  Index: locks.h
  ===================================================================
  RCS file: /home/cvs/apache-2.0/src/lib/apr/locks/unix/locks.h,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -r1.20 -r1.21
  --- locks.h	2000/04/22 06:16:33	1.20
  +++ locks.h	2000/06/03 00:31:14	1.21
  @@ -85,6 +85,9 @@
   #if HAVE_STDIO_H
   #include <stdio.h>
   #endif
  +#if HAVE_STDLIB_H
  +#include <stdlib.h>
  +#endif
   #if HAVE_FCNTL_H
   #include <fcntl.h>
   #endif
  
  
  

Mime
View raw message