diff -r 98dce985df09 test/runtime/jsig/Test8017498.sh
--- a/test/runtime/jsig/Test8017498.sh	Wed Apr 23 12:37:36 2014 +0200
+++ b/test/runtime/jsig/Test8017498.sh	Thu Apr 24 19:47:05 2014 +0400
@@ -35,11 +35,11 @@
 ## @run shell/timeout=60 Test8017498.sh
 ##
 
-if [ "${TESTSRC}" = "" ]
-then
-  TESTSRC=${PWD}
+if [ -z "${TESTSRC}" ]; then
+  TESTSRC="${PWD}"
   echo "TESTSRC not set.  Using "${TESTSRC}" as default"
 fi
+
 echo "TESTSRC=${TESTSRC}"
 ## Adding common setup Variables for running shell tests.
 . ${TESTSRC}/../../test_env.sh
@@ -52,12 +52,12 @@
   Linux)
     echo "Testing on Linux"
     gcc_cmd=`which gcc`
-    if [ "x$gcc_cmd" == "x" ]; then
+    if [ -z "$gcc_cmd" ]; then
         echo "WARNING: gcc not found. Cannot execute test." 2>&1
         exit 0;
     fi
     MY_LD_PRELOAD=${TESTJAVA}${FS}jre${FS}lib${FS}${VM_CPU}${FS}libjsig.so
-    if [ "$VM_BITS" == "32" ] && [ "$VM_CPU" != "arm" ] && [ "$VM_CPU" != "ppc" ]; then
+    if [ "$VM_BITS" = "32" ] && [ "$VM_CPU" != "arm" ] && [ "$VM_CPU" != "ppc" ]; then
             EXTRA_CFLAG=-m32
     fi
     echo MY_LD_PRELOAD = ${MY_LD_PRELOAD}
@@ -70,7 +70,7 @@
 
 THIS_DIR=.
 
-cp ${TESTSRC}${FS}*.java ${THIS_DIR}
+cp "${TESTSRC}${FS}"*.java "${THIS_DIR}"
 ${COMPILEJAVA}${FS}bin${FS}javac *.java
 
 $gcc_cmd -DLINUX -fPIC -shared \
@@ -84,12 +84,11 @@
 cmd="LD_PRELOAD=$MY_LD_PRELOAD \
     ${TESTJAVA}${FS}bin${FS}java \
     -Djava.library.path=${TESTSRC}${FS} -server TestJNI 100"
-echo "$cmd > test.out 2>&1"
-eval $cmd > test.out 2>&1
+echo "$cmd > test.out"
+eval $cmd > test.out
 
-grep "old handler" test.out > ${NULL}
-if [ $? = 0 ]
-then
+
+if grep "old handler" test.out > ${NULL}; then
     echo "Test Passed"
     exit 0
 fi
