Browse Source

fix sdtd config handling for the port

pull/3007/head
H3o66 5 years ago
parent
commit
94a8c5f62c
  1. 2
      lgsm/functions/info_config.sh

2
lgsm/functions/info_config.sh

@ -1231,7 +1231,7 @@ fn_info_config_sdtd(){
else else
servername=$(grep "ServerName" "${servercfgfullpath}" | sed 's/^.*value="//' | cut -f1 -d"\"") servername=$(grep "ServerName" "${servercfgfullpath}" | sed 's/^.*value="//' | cut -f1 -d"\"")
serverpassword=$(grep "ServerPassword" "${servercfgfullpath}" | sed 's/^.*value="//' | cut -f1 -d"\"") serverpassword=$(grep "ServerPassword" "${servercfgfullpath}" | sed 's/^.*value="//' | cut -f1 -d"\"")
port=$(grep "ServerPort" "${servercfgfullpath}" | tr -cd '[:digit:]') port=$(grep "ServerPort" "${servercfgfullpath}" | egrep -o 'value="[0-9]+"' | tr -cd '[:digit:]')
queryport=${port:-"0"} queryport=${port:-"0"}
webadminenabled=$(grep "ControlPanelEnabled" "${servercfgfullpath}" | sed 's/^.*value="//' | cut -f1 -d"\"") webadminenabled=$(grep "ControlPanelEnabled" "${servercfgfullpath}" | sed 's/^.*value="//' | cut -f1 -d"\"")

Loading…
Cancel
Save