From 146525ddd44618bc5664cd632a86ff14be1c3ba9 Mon Sep 17 00:00:00 2001 From: Yaroslav Brustinov Date: Wed, 24 Feb 2016 04:37:23 -0500 Subject: support bizarre replaced minuses from copy-paste from outlook etc. --- scripts/t-rex-64 | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'scripts/t-rex-64') diff --git a/scripts/t-rex-64 b/scripts/t-rex-64 index 1cf82489..0516d7da 100755 --- a/scripts/t-rex-64 +++ b/scripts/t-rex-64 @@ -4,7 +4,9 @@ if [ $USER != 'root' ]; then exit -1 fi -./trex-cfg $@ +INPUT_ARGS=${@//[–—]/-} # replace bizarre minuses with normal one + +./trex-cfg $INPUT_ARGS RESULT=$? if [ $RESULT -ne 0 ]; then exit $RESULT @@ -16,15 +18,15 @@ export LD_LIBRARY_PATH=$PWD saveterm="$(stty -g)" # if we have a new core run optimized trex if cat /proc/cpuinfo | grep -q avx ; then - ./_$(basename $0) $@ + ./_$(basename $0) $INPUT_ARGS if [ $? -eq 132 ]; then echo " WARNING this program is optimized for the new Intel processors. " echo " try the ./t-rex-64-o application that should work for any Intel processor but might be slower. " echo " try to run t-rex-64-o .. " - ./_t-rex-64-o $@ + ./_t-rex-64-o $INPUT_ARGS fi else - ./_t-rex-64-o $@ + ./_t-rex-64-o $INPUT_ARGS fi stty $saveterm -- cgit 1.2.3-korg