summaryrefslogtreecommitdiffstats
path: root/lang/gnat
diff options
context:
space:
mode:
authordeischen <deischen@FreeBSD.org>2002-02-12 23:43:24 +0000
committerdeischen <deischen@FreeBSD.org>2002-02-12 23:43:24 +0000
commitc71ebbe7d6958dddec8d1b51ef04aa7cc7147f1e (patch)
tree970b1120c045daf457be78c65d52762d3cd1259b /lang/gnat
parent98f9ba985c5ce3edf27eac0a75fb2fec09779671 (diff)
downloadFreeBSD-ports-c71ebbe7d6958dddec8d1b51ef04aa7cc7147f1e.zip
FreeBSD-ports-c71ebbe7d6958dddec8d1b51ef04aa7cc7147f1e.tar.gz
Add a patch to replace tmpnam with mkstemp.
Submitted by: Samuel Tardieu <sam@ada.eu.org>
Diffstat (limited to 'lang/gnat')
-rw-r--r--lang/gnat/files/patch-ap20
1 files changed, 20 insertions, 0 deletions
diff --git a/lang/gnat/files/patch-ap b/lang/gnat/files/patch-ap
new file mode 100644
index 0000000..aa61a67
--- /dev/null
+++ b/lang/gnat/files/patch-ap
@@ -0,0 +1,20 @@
+--- ada/a-adaint.c.orig Tue Feb 12 17:24:15 2002
++++ ada/a-adaint.c Tue Feb 12 17:21:56 2002
+@@ -590,6 +590,17 @@
+ strcpy (tmp_filename, pname);
+ free (pname);
+ }
++#elif defined (__FreeBSD__)
++ {
++ int fd;
++
++ strcpy (tmp_filename, "/tmp/gnat-XXXXXX");
++ fd = mkstemp (tmp_filename);
++ if (fd < 0)
++ strcpy (tmp_filename, "");
++ else
++ close (fd);
++ }
+ #else
+ tmpnam (tmp_filename);
+ #endif
OpenPOWER on IntegriCloud