mirror of
https://github.com/isc-projects/bind9.git
synced 2026-02-26 19:41:04 -05:00
Merge branch '4354-statschannel-test-opesbsd' into 'main'
Resolve "Checking zone transfer information in the statistics channel fails on OpenBSD" Closes #4354 See merge request isc-projects/bind9!8367
This commit is contained in:
commit
7fb4e354a9
1 changed files with 3 additions and 3 deletions
|
|
@ -714,10 +714,10 @@ n=$((n + 1))
|
|||
_wait_for_transfers() {
|
||||
getxfrins xml x$n || return 1
|
||||
getxfrins json j$n || return 1
|
||||
# XML is encoded in one line, use sed to separate each transfer
|
||||
count=$(sed 's/<xfrin /\n<xfrin /g' xfrins.xml.x$n | grep -c '<state>\(Zone Transfer Request\|First Data\|Receiving AXFR Data\)</state>')
|
||||
# XML is encoded in one line, use awk to separate each transfer with a newline
|
||||
count=$(awk '{ gsub("<xfrin ", "\n<xfrin ") } 1' xfrins.xml.x$n | grep -c -E '<state>(Zone Transfer Request|First Data|Receiving AXFR Data)</state>')
|
||||
if [ $count != 3 ]; then return 1; fi
|
||||
count=$(grep -c '"state":"\(Zone Transfer Request\|First Data\|Receiving AXFR Data\)"' xfrins.json.j$n)
|
||||
count=$(grep -c -E '"state":"(Zone Transfer Request|First Data|Receiving AXFR Data)"' xfrins.json.j$n)
|
||||
if [ $count != 3 ]; then return 1; fi
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue