This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch] use mkstemp instead of mktemp.


Hi All,
I was compiling the binutils from cvs and got the following warning ...

/backup/bleed/BINUTILS/src/binutils/bucomm.c:441: the use of `mktemp' is
dangerous, better use `mkstemp'

Let me know if the following is ok...
thanks,
Muthu

--- binutils/bucomm.c	Tue Jul  1 18:54:20 2003
+++ binutils-cvs/bucomm.c	Tue Jul  1 18:53:53 2003
@@ -438,14 +438,14 @@ make_tempname (filename)
 #endif
       strcat (tmpname, "/");
       strcat (tmpname, template);
-      mkstemp (tmpname);
+      mktemp (tmpname);
       *slash = c;
     }
   else
     {
       tmpname = xmalloc (sizeof (template));
       strcpy (tmpname, template);
-      mkstemp (tmpname);
+      mktemp (tmpname);
     }
   return tmpname;
 }



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]