Fix for Ubuntu 14.04

This commit is contained in:
Serghey Rodin 2014-07-30 15:29:50 +03:00
commit 2f300aab69

View file

@ -21,7 +21,7 @@ json_list_ns() {
ns=$(grep "^NS='" $USER_DATA/user.conf |cut -f 2 -d \') ns=$(grep "^NS='" $USER_DATA/user.conf |cut -f 2 -d \')
echo '[' echo '['
i=1 i=1
nslistc=$(echo -e "${ns//,/\n}"|wc -l) nslistc=$(echo -e "${ns//,/\\n}"|wc -l)
for nameserver in ${ns//,/ };do for nameserver in ${ns//,/ };do
if [ "$i" -ne "$nslistc" ]; then if [ "$i" -ne "$nslistc" ]; then
echo -e "\t\"$nameserver\"," echo -e "\t\"$nameserver\","