tools/bench-gossipd.sh: make sure we wait for gossipd to startup sync.

It can take a while if bitcoind has the regtest chain, and grossly
distorts our benchmarks!

Reported-by: Joe Netti <jnetti@blockstream.io>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell 2019-04-18 16:05:09 +09:30 committed by neil saitug
parent 902bb22a92
commit 1ccfbef4e7

View File

@ -23,6 +23,8 @@ wait_for_start()
exit 1
fi
done
# Wait for it to catch up with bitcoind.
while [ "$($LCLI1 -H getinfo 2>/dev/null | grep '^blockheight=' | cut -d= -f2)" != "$(bitcoin-cli -regtest getblockcount)" ]; do sleep 1; done
echo "$ID"
}