فهرست منبع

Adding more quotes around vars.

CedarLUG 9 سال پیش
والد
کامیت
03a051c1c6
1فایلهای تغییر یافته به همراه3 افزوده شده و 3 حذف شده
  1. 3 3
      lgsm/functions/command_postdetails.sh

+ 3 - 3
lgsm/functions/command_postdetails.sh

@@ -101,16 +101,16 @@ sed -i -r "s/[\x1B,\x0B]\[([0-9]{1,2}(;[0-9]{1,2})?)?[mGK]//g" "${tmpfile}"
 
 # If the gameserver uses anonymous steam credentials, leave them displayed
 # in the output.  Otherwise, strip these out as well.
-if ! grep -q "^steampass[= ]\"\"" ${tmpfile} ; then
+if ! grep -q "^steampass[= ]\"\"" "${tmpfile}" ; then
 	sed -i -e 's/steampass[= ]"[^"]*/steampass "--stripped--/' "${tmpfile}"
 fi
-if ! grep -q "^steamuser[= ]\"anonymous\"" ${tmpfile} ; then
+if ! grep -q "^steamuser[= ]\"anonymous\"" "${tmpfile}" ; then
 	sed -i -e 's/steamuser[= ]"[^"]*/steamuser "--stripped--/' "${tmpfile}"
 fi
 
 if [ "${posttarget}" == "http://pastebin.com" ] ; then 
    # grab the return from 'value' from an initial visit to pastebin.
-   csrftoken=$(curl -s ${posttarget} |
+   csrftoken=$(curl -s "${posttarget}" |
            sed -n 's/^.*input type="hidden" name="csrf_token_post" value="\(.*\)".*$/\1/p')
    # 
    # Use the csrftoken to then post the content.