Skip to content

Reset onion search rate for a friend when we see evidence that they are online - #1202

Merged
iphydf merged 1 commit into
TokTok:masterfrom
zugz:resetBackoff
Sep 24, 2018
Merged

iphydf merged 1 commit into
TokTok:masterfrom
zugz:resetBackoff

Conversation

@zugz

@zugz zugz commented Sep 24, 2018 •

Copy link
Copy Markdown

Combine last_reported_announced with last_seen in Onion_Friend.

This resets friend search rate in two circumstances where it should be
reset:

  • when the friend gets a dhtpk packet to us;
  • when a friend connection to the friend goes down.

This change is Reviewable

@codecov

codecov Bot commented Sep 24, 2018 •

Copy link
Copy Markdown

Codecov Report

Merging #1202 into master will increase coverage by 0.2%.
The diff coverage is 75%.

Impacted file tree graph

@@           Coverage Diff            @@
##           master   #1202     +/-   ##
========================================
+ Coverage    82.9%   83.1%   +0.2%     
========================================
  Files          82      82             
  Lines       14646   14645      -1     
========================================
+ Hits        12144   12176     +32     
+ Misses       2502    2469     -33
Impacted Files Coverage Δ
toxcore/onion_client.c 96.1% <75%> (-0.1%) ⬇️
toxcore/friend_connection.c 93.6% <0%> (-0.9%) ⬇️
toxcore/DHT.c 76.6% <0%> (-0.1%) ⬇️
toxcore/LAN_discovery.c 85.8% <0%> (+0.9%) ⬆️
toxav/toxav.c 68.1% <0%> (+0.9%) ⬆️
toxcore/net_crypto.c 94.3% <0%> (+1.2%) ⬆️
toxav/msi.c 66.4% <0%> (+1.9%) ⬆️
toxav/audio.c 70.5% <0%> (+4.8%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b694dbc...d5d6e3f. Read the comment docs.

This resets friend search rate in two circumstances where it should be
reset:
* When the friend gets a dhtpk packet to us;
* When a friend connection to the friend goes down.

@iphydf iphydf left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 1 of 1 files at r1.
Reviewable status: 0 of 1 approvals obtained

@iphydf
iphydf merged commit d5d6e3f into TokTok:master Sep 24, 2018
@iphydf

iphydf commented Sep 24, 2018

Copy link
Copy Markdown
Member

@zugz can you move the PR title to the description (because it's an implementation detail) and make the title something that users reading the changelog will understand (something closer to what the current description says, i.e. the effect on the behaviour)?

@zugz zugz changed the title Combine last_reported_announced with last_seen in Onion_Friend Reset onion search rate for a friend when we see evidence that they are online Sep 25, 2018
@zugz

zugz commented Sep 25, 2018

Copy link
Copy Markdown
Author

Done

@iphydf iphydf added this to the v0.2.x milestone Sep 25, 2018
@robinlinden robinlinden modified the milestones: v0.2.x, v0.2.8 Oct 7, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants