]> arthur.barton.de Git - netdata.git/commitdiff
reset IFS to previous one
authorpaulfantom <paulfantom@gmail.com>
Tue, 7 Jun 2016 22:29:31 +0000 (00:29 +0200)
committerpaulfantom <paulfantom@gmail.com>
Tue, 7 Jun 2016 22:29:31 +0000 (00:29 +0200)
charts.d/hddtemp.chart.sh

index 704ab9d02b37ae7cccf2934a33149d032f1586fd..91bac6cff592c83360ae1fbceb5d1bfe6473956d 100755 (executable)
@@ -41,9 +41,11 @@ hddtemp_count=0
 hddtemp_update() {
 #        local all=( `nc $hddtemp_host $hddtemp_port | sed -e 's/||/\n/g;s/^|//' | cut -d '|' -f3` )
 #      local all=( `nc $hddtemp_host $hddtemp_port | awk 'BEGIN { FS="|" };{i=4; while (i <= NF) {print $i+0;i+=5;};}'` )
+       OLD_IFS=$IFS
        set -f
        IFS="|" all=( $(nc $hddtemp_host $hddtemp_port) )
        set +f
+       IFS=$OLD_IFS
 
        # write the result of the work.
        echo "BEGIN hddtemp.temperature $1"