From 780bae9c420fd6c5bc743365a06fd94889dea4a1 Mon Sep 17 00:00:00 2001 From: bol-van Date: Fri, 5 Nov 2021 09:57:30 +0300 Subject: [PATCH] ipset: remove unneeded brackets in awk regexp --- ipset/get_reestr_combined.sh | 2 +- ipset/get_reestr_ip.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ipset/get_reestr_combined.sh b/ipset/get_reestr_combined.sh index 354e6a5..0e5ad2d 100755 --- a/ipset/get_reestr_combined.sh +++ b/ipset/get_reestr_combined.sh @@ -12,7 +12,7 @@ ZURL_REESTR=https://raw.githubusercontent.com/zapret-info/z-i/master/dump.csv awkgrep() { # $1 - pattern - nice -n 5 $AWK "{while ( match(\$0,/($1[ |;])/) ) { print substr(\$0,RSTART,RLENGTH-1); \$0=substr(\$0,RSTART+RLENGTH) } }" + nice -n 5 $AWK "{while ( match(\$0,/$1[ |;]/) ) { print substr(\$0,RSTART,RLENGTH-1); \$0=substr(\$0,RSTART+RLENGTH) } }" } dig_reestr() diff --git a/ipset/get_reestr_ip.sh b/ipset/get_reestr_ip.sh index a5e44a3..5be75f0 100755 --- a/ipset/get_reestr_ip.sh +++ b/ipset/get_reestr_ip.sh @@ -13,7 +13,7 @@ ZURL_REESTR=https://raw.githubusercontent.com/zapret-info/z-i/master/dump.csv awkgrep() { # $1 - pattern - nice -n 5 $AWK "{while ( match(\$0,/($1[ |;])/) ) { print substr(\$0,RSTART,RLENGTH-1); \$0=substr(\$0,RSTART+RLENGTH) } }" + nice -n 5 $AWK "{while ( match(\$0,/$1[ |;]/) ) { print substr(\$0,RSTART,RLENGTH-1); \$0=substr(\$0,RSTART+RLENGTH) } }" } dig_reestr()