|
From: Nicholas N. <nj...@ca...> - 2003-11-01 14:51:08
|
CVS commit by nethercote:
Make the startup static and suid checks follow symlinks.
Also a couple of minor formatting changes.
M +6 -6 valgrind.in 1.37
--- valgrind/coregrind/valgrind.in #1.36:1.37
@@ -118,11 +118,11 @@
which_prog=`which $1 2> /dev/null`
if [ z$which_prog = z ] ; then
- echo "'$1' not found in \$PATH, aborting."
- exit
+ echo "'$1' not found in \$PATH, aborting."
+ exit
fi
- # Ensure the program isn't statically linked.
if [ $# != 0 ] ; then
- case `file "$which_prog"` in
+ case `file -L "$which_prog"` in # must follow symlinks, hence -L
+ # Ensure the program isn't statically linked.
*"statically linked"*)
echo "\`$which_prog' is statically linked"
@@ -131,7 +131,7 @@
echo "to work with it. Read FAQ #5 for more information."
exit 1 ;;
- # ensure that there are no setuid or gid flags
+ # Ensure that there are no setuid or gid flags
*:\ set?id\ ELF*)
- echo "\`$which_prog' is suid/sgid."
+ echo "\`$which_prog' is suid/sgid."
echo "Valgrind can't handle these executables, as it"
echo "requires the LD_PRELOAD feature in order to work."
|