Sfoglia il codice sorgente

one more fix for OR syntax in grep

Serghey Rodin 12 anni fa
parent
commit
4ecf44d41b
1 ha cambiato i file con 1 aggiunte e 1 eliminazioni
  1. 1 1
      bin/v-add-dns-record

+ 1 - 1
bin/v-add-dns-record

@@ -39,7 +39,7 @@ if [ "$rtype" != 'MX' ] && [ "$rtype" != 'SRV' ]; then
 fi
 
 # Add trailing dot at the end of NS/CNAME/MX/PTR/SRV record
-fqdn_type=$(echo $rtype | grep "[NS|CNAME|MX|PTR|SRV]")
+fqdn_type=$(echo $rtype |grep "NS\|CNAME\|MX\|PTR\|SRV")
 if [ ! -z "$fqdn_type" ]; then
     trailing_dot=$(echo $dvalue | grep "\.$")
     if [ -z $trailing_dot ]; then