From: Julian Seward Date: Mon, 26 Sep 2011 16:46:04 +0000 (+0000) Subject: Print a slightly less useless failure message if VG_(mkstemp) fails to X-Git-Tag: svn/VALGRIND_3_7_0~189 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=34a86e3b101a5e61ee611f39e4f3aaf86d4a5da4;p=thirdparty%2Fvalgrind.git Print a slightly less useless failure message if VG_(mkstemp) fails to create a temp file, as often happens on Android. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@12048 --- diff --git a/coregrind/m_libcfile.c b/coregrind/m_libcfile.c index 10fab9d7e8..d5b425dff5 100644 --- a/coregrind/m_libcfile.c +++ b/coregrind/m_libcfile.c @@ -637,8 +637,10 @@ Int VG_(mkstemp) ( HChar* part_of_name, /*OUT*/HChar* fullname ) sres = VG_(open)(buf, VKI_O_CREAT|VKI_O_RDWR|VKI_O_EXCL|VKI_O_TRUNC, VKI_S_IRUSR|VKI_S_IWUSR); - if (sr_isError(sres)) + if (sr_isError(sres)) { + VG_(umsg)("VG_(mkstemp): failed to create temp file: %s\n", buf); continue; + } /* VG_(safe_fd) doesn't return if it fails. */ fd = VG_(safe_fd)( sr_Res(sres) ); if (fullname)