|
From: <sv...@va...> - 2014-08-09 21:46:04
|
Author: florian
Date: Sat Aug 9 21:45:56 2014
New Revision: 14252
Log:
Use mkstemp_format in VG_(mkstemp). That way nothing breaks should
the format change.
Modified:
trunk/coregrind/m_libcfile.c
Modified: trunk/coregrind/m_libcfile.c
==============================================================================
--- trunk/coregrind/m_libcfile.c (original)
+++ trunk/coregrind/m_libcfile.c Sat Aug 9 21:45:56 2014
@@ -709,7 +709,7 @@
return tmpdir;
}
-static const HChar *mkstemp_format = "%s/valgrind_%s_%08x";
+static const HChar mkstemp_format[] = "%s/valgrind_%s_%08x";
SizeT VG_(mkstemp_fullname_bufsz) ( SizeT part_of_name_len )
{
@@ -742,7 +742,7 @@
while (True) {
if (tries++ > 10)
return -1;
- VG_(sprintf)( buf, "%s/valgrind_%s_%08x",
+ VG_(sprintf)( buf, mkstemp_format,
tmpdir, part_of_name, VG_(random)( &seed ));
if (0)
VG_(printf)("VG_(mkstemp): trying: %s\n", buf);
|