aboutsummaryrefslogtreecommitdiff
path: root/gnu/gnunet/nse
diff options
context:
space:
mode:
authorMaxime Devos <maximedevos@telenet.be>2021-08-18 21:11:23 +0200
committerMaxime Devos <maximedevos@telenet.be>2021-09-21 12:15:27 +0200
commit2ca0c5b570be219b9ec9d8be81f38c2319fa32c6 (patch)
tree44add3211d82f283d097362187ce84be1eb0985f /gnu/gnunet/nse
parent4145b464536e599d6052da48a573a29e6ffc901c (diff)
downloadgnunet-scheme-2ca0c5b570be219b9ec9d8be81f38c2319fa32c6.tar.gz
gnunet-scheme-2ca0c5b570be219b9ec9d8be81f38c2319fa32c6.zip
nse: Allow 'updated' to be absent.
Fixes: https://notabug.org/maximed/scheme-gnunet/issues/4 * gnu/gnunet/nse/client.scm (connect)[handle-estimate]: Only call 'updated' if it isn't false. * tests/network-size.scm (act-as-the-server, estimate->list): Extract from "Client calls call-back (and sets estimates) in-order". ("likewise, without 'updated' or 'connected' (issue 4)"): Test it.
Diffstat (limited to 'gnu/gnunet/nse')
-rw-r--r--gnu/gnunet/nse/client.scm3
1 files changed, 2 insertions, 1 deletions
diff --git a/gnu/gnunet/nse/client.scm b/gnu/gnunet/nse/client.scm
index 8ac0d8e..dccca2d 100644
--- a/gnu/gnunet/nse/client.scm
+++ b/gnu/gnunet/nse/client.scm
@@ -133,7 +133,8 @@ procedure should accept the new estimate."
133 (read% /:msg:nse:estimate '(std-deviation) estimate-slice) 133 (read% /:msg:nse:estimate '(std-deviation) estimate-slice)
134 (read% /:msg:nse:estimate '(timestamp) estimate-slice))) 134 (read% /:msg:nse:estimate '(timestamp) estimate-slice)))
135 (atomic-box-set! estimate/box estimate) 135 (atomic-box-set! estimate/box estimate)
136 (updated estimate)) 136 (when updated
137 (updated estimate)))
137 (define handlers 138 (define handlers
138 (message-handlers 139 (message-handlers
139 (make-message-handler (symbol-value message-type msg:nse:estimate) 140 (make-message-handler (symbol-value message-type msg:nse:estimate)