public inbox for nncp-devel@lists.cypherpunks.ru
Atom feed
* nncp-xfer not respecting -seen
@ 2022-03-05 15:51 John Goerzen
  2022-03-09 11:59 ` Sergey Matveev
  0 siblings, 1 reply; 2+ messages in thread
From: John Goerzen @ 2022-03-05 15:51 UTC (permalink / raw)
  To: nncp-devel

Hi Sergey,

In running this new code in 8.7.0, I've been observing the occasional
duplicate processing of a packet.  That's surprising to me, because I
use -seen with nncp-toss at every possible location.

Diving into it a bit, I see that:

1) An appropriate file is being created in seen/ after the first toss

2) When nncp-xfer -rx is used over a directory containing a packet that
has previously been seen, it generates an ACK for it (probably the right
thing to do) and but also the packet is placed into rx (probably not the
right thing to do)

3) nncp-toss will process it again despite the existence of seen/ for
it.

I looked at the code a bit, and it seems that the seen check is done
during the rx path of nncp-bundle and the tx path of nncp-xfer.  My
intuition says the nncp-bundle approach is correct but I may be
misunderstanding the code here.

Thanks!

- John

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: nncp-xfer not respecting -seen
  2022-03-05 15:51 nncp-xfer not respecting -seen John Goerzen
@ 2022-03-09 11:59 ` Sergey Matveev
  0 siblings, 0 replies; 2+ messages in thread
From: Sergey Matveev @ 2022-03-09 11:59 UTC (permalink / raw)
  To: nncp-devel

[-- Attachment #1: Type: text/plain, Size: 562 bytes --]

Greetings!

*** John Goerzen [2022-03-05 09:51]:
>I looked at the code a bit, and it seems that the seen check is done
>during the rx path of nncp-bundle and the tx path of nncp-xfer.  My
>intuition says the nncp-bundle approach is correct but I may be
>misunderstanding the code here.

You are totally right! I have no idea what was the point of seen-file
checking for -tx path -- it is pointless. Fixed that in 8.7.1 release.
Thank you!

-- 
Sergey Matveev (http://www.stargrave.org/)
OpenPGP: CF60 E89A 5923 1E76 E263  6422 AE1A 8109 E498 57EF

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-03-09 11:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-05 15:51 nncp-xfer not respecting -seen John Goerzen
2022-03-09 11:59 ` Sergey Matveev