+/* $OpenLDAP$ */
#include "portable.h"
#ifndef HAVE_TEMPNAM
-#include <stdlib.h>
-#include <stdlib.h>
+#include <stdio.h>
+
+#include <ac/stdlib.h>
#include <ac/string.h>
-extern char *mktemp (char *);
+#include <ac/unistd.h>
#include "lutil.h"
char *
-tempnam( char *dir, char *pfx )
+(tempnam)( const char *dir, const char *pfx )
{
char *s;
if ( dir == NULL ) {
- dir = "/tmp";
+ dir = LDAP_TMPDIR;
}
/*
return( s );
}
-#endif /* nextstep */
+#endif /* TEMPNAM */