More useless cat

This commit is contained in:
Mark Felder 2015-03-13 15:19:47 -05:00
parent 4cdc89aa61
commit 8d965f7c71

View File

@ -311,7 +311,7 @@ EOF
) &>$HEADERFILE_BREACH & ) &>$HEADERFILE_BREACH &
pid=$! pid=$!
if wait_kill $pid $HEADER_MAXSLEEP; then if wait_kill $pid $HEADER_MAXSLEEP; then
result=$(cat $HEADERFILE_BREACH | grep -a '^Content-Encoding' | sed -e 's/^Content-Encoding//' -e 's/://' -e 's/ //g') result=$(grep -a '^Content-Encoding' $HEADERFILE_BREACH | sed -e 's/^Content-Encoding//' -e 's/://' -e 's/ //g')
result=$(echo $result | tr -cd '\40-\176') result=$(echo $result | tr -cd '\40-\176')
if [ -z $result ]; then if [ -z $result ]; then
pr_green "no HTTP compression (OK) " pr_green "no HTTP compression (OK) "
@ -392,7 +392,7 @@ EOF
pid=$! pid=$!
if wait_kill $pid $HEADER_MAXSLEEP; then if wait_kill $pid $HEADER_MAXSLEEP; then
if ! egrep -iq "XML|HTML|DOCTYPE|HTTP|Connection" $HEADERFILE; then if ! egrep -iq "XML|HTML|DOCTYPE|HTTP|Connection" $HEADERFILE; then
pr_litemagenta "likely HTTP header requests failed (#lines: $(cat $HEADERFILE | wc -l))." pr_litemagenta "likely HTTP header requests failed (#lines: $(wc -l $HEADERFILE))."
outln "Rerun with DEBUG=1 and inspect \"http_header.txt\"\n" outln "Rerun with DEBUG=1 and inspect \"http_header.txt\"\n"
debugme cat $HEADERFILE debugme cat $HEADERFILE
ret=7 ret=7