Merge pull request #6607 from urbit/yu/fix-drop-nack

ames: don't no-op if getting %ack on nack bone
This commit is contained in:
Ted Blackman 2023-05-26 10:19:31 -04:00 committed by GitHub
commit d234b3205f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3368,20 +3368,17 @@
:: ::
=. snd.peer-state (~(del by snd.peer-state) bone) =. snd.peer-state (~(del by snd.peer-state) bone)
peer-core peer-core
:: if odd bone, ack is on "subscription update" message; no-op ?: =(1 (end 0 bone))
:: :: ack is on "subscription update" message; no-op
?: =(1 (end 0 bone)) peer-core ::
:: even bone; is this bone a nack-trace bone? ?: =(0 (end 0 (rsh 0 bone))) peer-core
:: :: nack-trace bone; assume .ok, clear nack from |sink
?: =(1 (end 0 (rsh 0 bone)))
:: nack-trace bone; assume .ok, clear nack from |message-sink
:: ::
abet:(call:(abed:mi (mix 0b10 bone)) %drop message-num) abet:(call:(abed:mi (mix 0b10 bone)) %drop message-num)
?: &(closing ?=(%near -.task)) :: if the bone belongs to a closing flow and we got a
:: if the bone belongs to a closing flow and we got a :: naxplanation, don't relay ack to the client vane
:: naxplanation, don't relay ack to the client vane ::
:: ?: &(closing ?=(%near -.task)) peer-core
peer-core
:: not a nack-trace bone; relay ack to client vane :: not a nack-trace bone; relay ack to client vane
:: ::
(pe-emit (got-duct bone) %give %done error) (pe-emit (got-duct bone) %give %done error)