Skip to content

Commit 62e1423

Browse files
cdeckerniftynei
authored andcommitted
fixup! tools/bench-gossipd.sh: make it work (where possible) with DEVELOPER=0
1 parent 14ef3e9 commit 62e1423

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

tools/bench-gossipd.sh

+3-3
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ fi
7979

8080
DEVELOPER=$(grep '^DEVELOPER=' config.vars | cut -d= -f2-)
8181

82-
if [ $DEVELOPER = 1 ]; then
82+
if [ "$DEVELOPER" = 1 ]; then
8383
LIGHTNINGD="./lightningd/lightningd --network=regtest --dev-gossip-time=1550513768 --dev-unknown-channel-satoshis=100000"
8484
else
8585
# Means we can't do the peer_read_all test properly, since it will time out.
@@ -117,7 +117,7 @@ if [ -z "${TARGETS##* vsz_kb *}" ]; then
117117
fi
118118

119119
# How long does rewriting the store take?
120-
if [ -z "${TARGETS##* store_rewrite_sec *}" -a "$DEVELOPER" = 1 ]; then
120+
if [ -z "${TARGETS##* store_rewrite_sec *}" ] && [ "$DEVELOPER" = 1 ]; then
121121
# shellcheck disable=SC2086
122122
/usr/bin/time --append -f %e $LCLI1 dev-compact-gossip-store 2>&1 > /dev/null | print_stat store_rewrite_sec
123123
fi
@@ -154,7 +154,7 @@ fi
154154

155155
# Needs DEVELOPER otherwise timestamps will be more than 2 weeks old and it
156156
# will ignore gossip.
157-
if [ -z "${TARGETS##* peer_read_all_sec *}" -a "$DEVELOPER" = 1 ]; then
157+
if [ -z "${TARGETS##* peer_read_all_sec *}" ] && [ "$DEVELOPER" = 1 ]; then
158158
# shellcheck disable=SC2086
159159
$LCLI1 stop > /dev/null
160160
sleep 5

0 commit comments

Comments
 (0)