aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorflorian <florian@a5019735-40e9-0310-863c-91ae7b9d1cf9>2015-09-16 08:59:03 +0000
committerflorian <florian@a5019735-40e9-0310-863c-91ae7b9d1cf9>2015-09-16 08:59:03 +0000
commit0d77f50af3bd07c6227a7794852e419a06c62bb9 (patch)
tree4c9ca0211f51dfd568f5cef4ed249c8cfa4840ed
parent1537bb48cd26e5672027bfdb0d7a2aab2d26c65d (diff)
downloadvalgrind-0d77f50af3bd07c6227a7794852e419a06c62bb9.tar.gz
Pick up 'egrep' and 'strings' from $PATH instead of using
hardwired absolute path names. People can always arrange $PATH such that these tools are found. Fixes BZ #294065. Patch by Austin English <austinenglish@gmail.com> git-svn-id: svn://svn.valgrind.org/valgrind/trunk@15652 a5019735-40e9-0310-863c-91ae7b9d1cf9
-rw-r--r--NEWS1
-rw-r--r--coregrind/m_debuginfo/readpdb.c4
2 files changed, 3 insertions, 2 deletions
diff --git a/NEWS b/NEWS
index 7119ab8b8..872a56011 100644
--- a/NEWS
+++ b/NEWS
@@ -193,6 +193,7 @@ where XXXXXX is the bug number as listed below.
226609 Crediting upstream authors in man page
231257 Valgrind omits path when executing script from shebang line
254164 OS X task_info: UNKNOWN task message [id 3405, to mach_task_self() [..]
+294065 Improve the pdb file reader by avoiding hardwired absolute pathnames
269360 s390x: Fix addressing mode selection for compare-and-swap
302630 Memcheck: Assertion failed: 'sizeof(UWord) == sizeof(UInt)'
== 326797
diff --git a/coregrind/m_debuginfo/readpdb.c b/coregrind/m_debuginfo/readpdb.c
index 08a9f5681..8b63e9562 100644
--- a/coregrind/m_debuginfo/readpdb.c
+++ b/coregrind/m_debuginfo/readpdb.c
@@ -2503,8 +2503,8 @@ HChar* ML_(find_name_of_pdb_file)( const HChar* pename )
sh -c "strings (pename) | egrep '\.pdb$|\.PDB$' > (tmpname)"
*/
const HChar* sh = "/bin/sh";
- const HChar* strings = "/usr/bin/strings";
- const HChar* egrep = "/usr/bin/egrep";
+ const HChar* strings = "strings";
+ const HChar* egrep = "grep -E";
/* (sh) -c "(strings) (pename) | (egrep) 'pdb' > (tmpname) */
Int cmdlen = VG_(strlen)(strings) + VG_(strlen)(pename)