adaint.c (__gnat_tmp_name): RTSS applications do not support tempnam nor tmpnam...
authorJose Ruiz <ruiz@adacore.com>
Fri, 1 Aug 2008 07:56:32 +0000 (09:56 +0200)
committerArnaud Charlet <charlet@gcc.gnu.org>
Fri, 1 Aug 2008 07:56:32 +0000 (09:56 +0200)
2008-08-01  Jose Ruiz  <ruiz@adacore.com>

* adaint.c (__gnat_tmp_name): RTSS applications do not support tempnam
nor tmpnam, so we always use c:\WINDOWS\Temp\gnat-XXXXXX as temporary
name.

From-SVN: r138474

gcc/ada/adaint.c

index 29f649a..c131357 100644 (file)
@@ -982,7 +982,11 @@ __gnat_named_file_length (char *name)
 void
 __gnat_tmp_name (char *tmp_filename)
 {
-#ifdef __MINGW32__
+#ifdef RTX
+  /* RTX in RTSS mode does not support tempnam nor tmpnam */
+  strcpy (tmp_filename, "c:\\WINDOWS\\Temp\\gnat-XXXXXX");
+
+#elif defined (__MINGW32__)
   {
     char *pname;