noisy echo works, starting rubicon querier

This commit is contained in:
Peter Harpending
2026-09-02 20:38:08 -07:00
parent ede7d8e977
commit 66364fce04
3 changed files with 6 additions and 5 deletions
+3 -3
View File
@@ -20,9 +20,9 @@ main([]) -> main_ii(6969);
main([PortNum]) -> main_ii(list_to_integer(PortNum)).
main_ii(PortNum) ->
TcpOpts = [binary, {packet, 0}, {active, once}],
TcpOpts = [binary, {packet, 0}, {active, true}],
{ok, TSock} = gen_tcp:connect("localhost", PortNum, TcpOpts),
ok = inet:setopts(TSock, [{active, once}]),
%ok = inet:setopts(TSock, [{active, once}]),
{ok, NSock, _HandshakeState} = enoise:connect(TSock, noise_options()),
% need keyboard process
Self = self(),
@@ -37,7 +37,7 @@ noise_options() ->
j_loop(JS = #js{rcv = Rcv, tsock = TSock, nsock = NSock}) ->
ok = inet:setopts(TSock, [{active, once}]),
%ok = inet:setopts(TSock, [{active, once}]),
receive
{noise, NSock, Bytes} ->
NewRcv = <<Rcv/binary, Bytes/binary>>,