summaryrefslogtreecommitdiff
path: root/src/utils
diff options
context:
space:
mode:
authorwlemb <wlemb>2001-07-20 14:36:50 +0000
committerwlemb <wlemb>2001-07-20 14:36:50 +0000
commit0c2857af24a536366560a8a13c64fd6ea25f8408 (patch)
tree581239e098ec25f99e3939b5eca17f5054061dbc /src/utils
parent8ec25476b88dc3138d74c285cf249a90200ae6ac (diff)
downloadgroff-0c2857af24a536366560a8a13c64fd6ea25f8408.tar.gz
* src/libs/libgroff/tmpname.cc: New file, defining get_tempname().
* src/libs/libgroff/mkstemp.cc: New file. * src/libs/libgroff/mksdir.cc: New file. * src/libs/libgroff/tmpfile.cc [HAVE_MKSTEMP_PROTO]: Removed. (xtmpfile) [!HAVE_MKSTEMP]: Removed. * src/libs/libgroff/Makefile.sub: Updated. * src/include/lib.h: Add mksdir() prototype. * src/include/posix.h: Define S_IXUSR if not yet defined. * src/preproc/html/pre-html.cc (MAX_RETRIES): Removed. (createAllPages): Use mksdir() instead of current code. * src/utils/indxbib/indxbib.cc [HAVE_MKSTEMP_PROTO]: Removed. (main): [!HAVE_MKSTEMP]: Removed. * aclocal.m4 (GROFF_MKSTEMP): Updated to use new mkstemp.cc file. (GROFF_INTTYPES_H, GROFF_UNSIGNED_LONG_LONG, GROFF_UINTMAX_T): New macros. * configure.ac: Add tests for stdint.h, sys/time.h, and gettimeofday(). Call new GROFF_xxx macros. * configure: Regenerated. * Makefile.in: Comments updated.
Diffstat (limited to 'src/utils')
-rw-r--r--src/utils/afmtodit/afmtodit.pl2
-rw-r--r--src/utils/indxbib/indxbib.cc14
2 files changed, 1 insertions, 15 deletions
diff --git a/src/utils/afmtodit/afmtodit.pl b/src/utils/afmtodit/afmtodit.pl
index bfc058a4..04bfe78e 100644
--- a/src/utils/afmtodit/afmtodit.pl
+++ b/src/utils/afmtodit/afmtodit.pl
@@ -1,6 +1,6 @@
#! /usr/bin/perl -P-
# -*- Perl -*-
-# Copyright (C) 1989-2000 Free Software Foundation, Inc.
+# Copyright (C) 1989-2000, 2001 Free Software Foundation, Inc.
# Written by James Clark (jjc@jclark.com)
#
# This file is part of groff.
diff --git a/src/utils/indxbib/indxbib.cc b/src/utils/indxbib/indxbib.cc
index db3e9a40..635d99df 100644
--- a/src/utils/indxbib/indxbib.cc
+++ b/src/utils/indxbib/indxbib.cc
@@ -39,12 +39,6 @@ Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
extern "C" const char *Version_string;
-#ifndef HAVE_MKSTEMP_PROTO
-extern "C" {
- extern int mkstemp(char *);
-}
-#endif
-
#define DEFAULT_HASH_TABLE_SIZE 997
#define TEMP_INDEX_TEMPLATE "indxbibXXXXXX"
@@ -240,16 +234,8 @@ int main(int argc, char **argv)
else {
temp_index_file = strsave(TEMP_INDEX_TEMPLATE);
}
-#ifndef HAVE_MKSTEMP
- if (!mktemp(temp_index_file) || !temp_index_file[0])
- fatal("cannot create file name for temporary file");
-#endif
catch_fatal_signals();
-#ifdef HAVE_MKSTEMP
int fd = mkstemp(temp_index_file);
-#else
- int fd = creat(temp_index_file, S_IRUSR|S_IRGRP|S_IROTH);
-#endif
if (fd < 0)
fatal("can't create temporary index file: %1", strerror(errno));
indxfp = fdopen(fd, FOPEN_WB);