Skip to content

Commit

Permalink
fix awk script, adjust to newer netcat versions
Browse files Browse the repository at this point in the history
  • Loading branch information
john30 committed Feb 14, 2021
1 parent c1e7ba5 commit 024bf84
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions contrib/scripts/makegrabcsv.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ if [ "x$1" = "x-m" ]; then
shift
maxidlen=$1
fi
echo "grab result"|nc localhost $port|awk -vmaxidlen=$maxidlen '
echo "grab result"|nc -N localhost $port|awk -vmaxidlen=$maxidlen '
BEGIN{
sdatas[""]=0
delete sdatas[""]
Expand All @@ -27,8 +27,8 @@ BEGIN{
exit
}
/.+/ {
m=gensub(" ", "", "g", gensub("=.*$", "", "", $1))
s=gensub(" ", "", "g", gensub("=.*$", "", "", $2))
m=gensub(" ", "", "g", gensub("=.*$", "", 1, $1))
s=gensub(" ", "", "g", gensub("=.*$", "", 1, $2))
pbsbnnid=substr(m,5,(3+maxidlen)*2)
if (!shorted[pbsbnnid]) {
shorted[pbsbnnid]=1
Expand Down

0 comments on commit 024bf84

Please sign in to comment.