aboutsummaryrefslogtreecommitdiff
path: root/include/pub_tool_libcfile.h
diff options
context:
space:
mode:
authorflorian <florian@a5019735-40e9-0310-863c-91ae7b9d1cf9>2014-09-27 17:42:07 +0000
committerflorian <florian@a5019735-40e9-0310-863c-91ae7b9d1cf9>2014-09-27 17:42:07 +0000
commit29d82f6e5ff3af28950ef6071d231b9633f82a49 (patch)
tree16d339a021a0e78ee3d78f74b8d8d00b3fa40a17 /include/pub_tool_libcfile.h
parent58946e936476d805bd0d311a791c6eb8cff1b879 (diff)
downloadvalgrind-29d82f6e5ff3af28950ef6071d231b9633f82a49.tar.gz
Merge 14206,14207,14261,14577,14578 from BUF_REMOVAL branch to trunk.
This changes VG_(record_startup_wd) to dynamically allocate a large enough buffer for the directory name. As the dynamic memory manager has started up a while ago, this is quite safe. Also rewrite VG_(get_startup_wd) to simply return the directory name. No more messing with copying it around. Adapt call sites. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@14579 a5019735-40e9-0310-863c-91ae7b9d1cf9
Diffstat (limited to 'include/pub_tool_libcfile.h')
-rw-r--r--include/pub_tool_libcfile.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/pub_tool_libcfile.h b/include/pub_tool_libcfile.h
index ea50289b2..bb1a6e4f7 100644
--- a/include/pub_tool_libcfile.h
+++ b/include/pub_tool_libcfile.h
@@ -103,9 +103,9 @@ extern const HChar* VG_(dirname) ( const HChar* path );
/* Return the name of a directory for temporary files. */
extern const HChar* VG_(tmpdir)(void);
-/* Copy the working directory at startup into buf[0 .. size-1], or return
- False if buf is too small. */
-extern Bool VG_(get_startup_wd) ( HChar* buf, SizeT size );
+/* Return the working directory at startup. The returned string is
+ persistent. */
+extern const HChar *VG_(get_startup_wd) ( void );
#endif // __PUB_TOOL_LIBCFILE_H