Merge branch 'ames-goof' (#2166)

* origin/ames-goof:
  ames: adjust route update logic

Signed-off-by: Jared Tobin <jared@tlon.io>
This commit is contained in:
Jared Tobin 2020-01-22 13:14:39 +04:00
commit c182672b54
No known key found for this signature in database
GPG Key ID: 0E4647D58F8A69E4
2 changed files with 11 additions and 6 deletions

View File

@ -1,3 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:d89d1363875673646bfdf6cf37c2b5d07d085cf5cf64a604875289c09fb653aa
size 9633371
oid sha256:e6232e5bcb64be057ccd9b4c23bbd636814d50778e4f3a01fbf2ee0042fe3d44
size 9635072

View File

@ -1477,10 +1477,15 @@
?> =(rcvr-life.shut-packet our-life.channel)
:: non-galaxy: update route with heard lane or forwarded lane
::
=? route.peer-state
?& !=(%czar (clan:title her.channel))
!=([~ %& *] route.peer-state)
==
=? route.peer-state
?: =(%czar (clan:title her.channel))
%.n
=/ is-old-direct=? ?=([~ %& *] route.peer-state)
=/ is-new-direct=? ?=(~ origin.packet)
:: old direct takes precedence over new indirect
::
|(is-new-direct !is-old-direct)
::
?~ origin.packet
`[direct=%.y lane]
`[direct=%.n u.origin.packet]