diff options
author | Renato Botelho <renato@netgate.com> | 2016-01-21 18:08:37 -0200 |
---|---|---|
committer | Renato Botelho <renato@netgate.com> | 2016-01-21 18:08:37 -0200 |
commit | fd5e3a0800bd0a437f86054efd10827847907f6e (patch) | |
tree | 0f47a28c1a78987eb531eadf7f690b68ad5e1f1f | |
parent | d3f4dfc1c35e540f590fae5a22a0079959af8ce9 (diff) | |
parent | 9f268ac020eb067cd0ee873ce93904b6a1dadece (diff) | |
download | pfsense-fd5e3a0800bd0a437f86054efd10827847907f6e.zip pfsense-fd5e3a0800bd0a437f86054efd10827847907f6e.tar.gz |
Merge pull request #2496 from dennypage/master
-rw-r--r-- | src/etc/inc/rrd.inc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/etc/inc/rrd.inc b/src/etc/inc/rrd.inc index 0d0715b..7019a28 100644 --- a/src/etc/inc/rrd.inc +++ b/src/etc/inc/rrd.inc @@ -984,14 +984,14 @@ for sock in {$g['varrun_path']}/dpinger_*.sock; do continue fi - gw=\$(/usr/bin/nc -U \$sock | awk '{ print \$1 }') - - if [ -z "\$gw" ]; then + t=\$(/usr/bin/nc -U \$sock) + if [ -z "\$t" ]; then continue fi - delay=\$(/usr/bin/nc -U \$sock | awk '{ print \$2 }') - loss=\$(/usr/bin/nc -U \$sock | awk '{ print \$4 }') + gw=\$(echo "\$t" | awk '{ print \$1 }') + delay=\$(echo "\$t" | awk '{ print \$2 }') + loss=\$(echo "\$t" | awk '{ print \$4 }') if echo "\$loss" | grep -Eqv '^[0-9]+\$'; then loss="U" |