GNU bug report logs -
#29001
[wishlist] configure option to disable tmpnam
Previous Next
Reported by: Matt Wette <matt.wette <at> gmail.com>
Date: Thu, 26 Oct 2017 00:27:01 UTC
Severity: wishlist
Done: Ludovic Courtès <ludo <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
It would be nice to have a configure option to disable/enable including the POSIX function tmpnam.
It may give Guile a more "code secure" option to have the default be disabled.
I tried to generate a patch, but I could not get it to work both ways (disable and enable). My autoconf
knowledge and skills are lacking.
Here is what I tried (THIS DOES NOT WORK)
--- libguile/posix.c-orig 2017-10-24 05:28:30.000000000 -0700
+++ libguile/posix.c 2017-10-24 05:28:51.000000000 -0700
@@ -1557,6 +1557,7 @@
}
#undef FUNC_NAME
+#ifdef ENABLE_TMPNAM
#ifdef L_tmpnam
SCM_DEFINE (scm_tmpnam, "tmpnam", 0, 0, 0,
@@ -1580,6 +1581,7 @@
#undef FUNC_NAME
#endif
+#endif
SCM_DEFINE (scm_tmpfile, "tmpfile", 0, 0, 0,
(void),
--- configure.ac-orig 2017-10-24 05:21:56.000000000 -0700
+++ configure.ac 2017-10-25 16:07:34.000000000 -0700
@@ -164,6 +164,10 @@
[ --disable-regex omit regular expression interfaces],,
enable_regex=yes)
+AC_ARG_ENABLE(tmpnam,
+ [ --enable-tmpnam enable POSIX tmpnam],
+ enable_tmpnam=yes, enable_tmpnam=no)
+
AC_ARG_ENABLE([deprecated],
AS_HELP_STRING([--disable-deprecated],[omit deprecated features]))
^--- DOES NOT WORK
[Message part 2 (text/html, inline)]
This bug report was last modified 5 years and 154 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.