Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(155)

Issue 937743003: Fix MDnsClient's cache entry cleanup logic. (Closed)

Created:
5 years, 10 months ago by Kevin M
Modified:
5 years, 9 months ago
CC:
chromium-reviews, cbentzel+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix MDnsClient's cache entry cleanup logic. The current implementation has an error in its time delay computation. It computes negative timedeltas for cache entries that are > Now(). This causes a CHECK failure in IncomingTaskQueue::CalculateDelayedRuntime. BUG=459443 CC=mfoltz@chromium.org Committed: https://crrev.com/3e740be5fa1026ae8b39d99f1180b7c39b9d4b12 Cr-Commit-Position: refs/heads/master@{#318766}

Patch Set 1 #

Patch Set 2 : Add unit tests; miscellaneous lint fixes #

Total comments: 7

Patch Set 3 : Use base::Clock throughout MDnsClientImpl #

Total comments: 4

Patch Set 4 : Formatting fixes. #

Patch Set 5 : Formatting #

Unified diffs Side-by-side diffs Delta from patch set Stats (+276 lines, -149 lines) Patch
M net/dns/mdns_client_impl.h View 1 2 8 chunks +22 lines, -3 lines 0 comments Download
M net/dns/mdns_client_impl.cc View 1 2 3 11 chunks +46 lines, -34 lines 0 comments Download
M net/dns/mdns_client_unittest.cc View 1 2 3 4 31 chunks +208 lines, -112 lines 0 comments Download

Messages

Total messages: 38 (8 generated)
Kevin M
5 years, 10 months ago (2015-02-18 19:49:56 UTC) #3
cbentzel
gene: I'll take a look but wanted you to see as well.
5 years, 10 months ago (2015-02-18 21:19:13 UTC) #6
cbentzel
gene: I'll take a look but wanted you to see as well.
5 years, 10 months ago (2015-02-18 21:19:13 UTC) #7
cbentzel
gene: I'll take a look but wanted you to see as well.
5 years, 10 months ago (2015-02-18 21:19:14 UTC) #8
cbentzel
gene: I'll take a look but wanted you to see as well.
5 years, 10 months ago (2015-02-18 21:19:15 UTC) #9
cbentzel
Can this get a test?
5 years, 10 months ago (2015-02-18 21:21:08 UTC) #10
gene
Thanks Chris. This looks good to me.
5 years, 10 months ago (2015-02-18 21:56:20 UTC) #11
mark a. foltz
lgtm
5 years, 10 months ago (2015-02-18 23:11:11 UTC) #12
cbentzel
On 2015/02/18 23:11:11, mark a. foltz wrote: > lgtm Any chance for a test for ...
5 years, 10 months ago (2015-02-22 13:39:24 UTC) #13
Kevin M
Hi Chris, I'm writing the tests now. My original testing efforts involved moving the code ...
5 years, 10 months ago (2015-02-23 17:36:19 UTC) #14
Kevin M
OK, added a targeted test. Please take a look.
5 years, 10 months ago (2015-02-24 23:43:13 UTC) #15
mark a. foltz
https://codereview.chromium.org/937743003/diff/20001/net/dns/mdns_client_impl.cc File net/dns/mdns_client_impl.cc (right): https://codereview.chromium.org/937743003/diff/20001/net/dns/mdns_client_impl.cc#newcode415 net/dns/mdns_client_impl.cc:415: base::Bind(&MDnsClientImpl::Core::OnRecordRemoved, What cancels this callback when MDnsClientImpl is deleted? ...
5 years, 10 months ago (2015-02-25 21:44:07 UTC) #16
Kevin M
https://codereview.chromium.org/937743003/diff/20001/net/dns/mdns_client_impl.cc File net/dns/mdns_client_impl.cc (right): https://codereview.chromium.org/937743003/diff/20001/net/dns/mdns_client_impl.cc#newcode415 net/dns/mdns_client_impl.cc:415: base::Bind(&MDnsClientImpl::Core::OnRecordRemoved, On 2015/02/25 21:44:07, mark a. foltz wrote: > ...
5 years, 10 months ago (2015-02-26 01:04:41 UTC) #17
mark a. foltz
lgtm https://codereview.chromium.org/937743003/diff/20001/net/dns/mdns_client_impl.cc File net/dns/mdns_client_impl.cc (right): https://codereview.chromium.org/937743003/diff/20001/net/dns/mdns_client_impl.cc#newcode415 net/dns/mdns_client_impl.cc:415: base::Bind(&MDnsClientImpl::Core::OnRecordRemoved, On 2015/02/26 01:04:40, Kevin M wrote: > ...
5 years, 10 months ago (2015-02-26 01:18:03 UTC) #18
Kevin M
Thanks Mark. cbentzel, gene, PTAL.
5 years, 9 months ago (2015-02-26 18:00:33 UTC) #19
Kevin M
I just had a watercooler conversation with miu@ about this and he advised me to ...
5 years, 9 months ago (2015-02-26 19:46:33 UTC) #20
mmenke
On 2015/02/26 19:46:33, Kevin M wrote: > I just had a watercooler conversation with miu@ ...
5 years, 9 months ago (2015-02-26 20:13:00 UTC) #21
miu
On 2015/02/26 20:13:00, mmenke wrote: > Just a drive by comment: Time doesn't increase monotonically, ...
5 years, 9 months ago (2015-02-26 20:22:18 UTC) #22
Kevin M
The fix in this CL makes the code handle skew more gracefully.
5 years, 9 months ago (2015-02-27 00:18:30 UTC) #23
gene
lgtm. two small nits
5 years, 9 months ago (2015-03-02 18:43:10 UTC) #24
Kevin M
Thanks Gene. I don't see your nits, though?
5 years, 9 months ago (2015-03-02 18:47:47 UTC) #25
gene
https://codereview.chromium.org/937743003/diff/40001/net/dns/mdns_client_unittest.cc File net/dns/mdns_client_unittest.cc (right): https://codereview.chromium.org/937743003/diff/40001/net/dns/mdns_client_unittest.cc#newcode242 net/dns/mdns_client_unittest.cc:242: 0x00, 0x00, // TTL (4 bytes) is 1 second; ...
5 years, 9 months ago (2015-03-02 19:37:16 UTC) #26
Kevin M
https://codereview.chromium.org/937743003/diff/40001/net/dns/mdns_client_unittest.cc File net/dns/mdns_client_unittest.cc (right): https://codereview.chromium.org/937743003/diff/40001/net/dns/mdns_client_unittest.cc#newcode242 net/dns/mdns_client_unittest.cc:242: 0x00, 0x00, // TTL (4 bytes) is 1 second; ...
5 years, 9 months ago (2015-03-02 20:23:46 UTC) #27
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/937743003/80001
5 years, 9 months ago (2015-03-02 20:25:44 UTC) #30
commit-bot: I haz the power
Try jobs failed on following builders: chromium_presubmit on tryserver.chromium.linux (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.linux/builders/chromium_presubmit/builds/46711)
5 years, 9 months ago (2015-03-02 20:42:26 UTC) #32
cbentzel
On 2015/03/02 20:42:26, I haz the power (commit-bot) wrote: > Try jobs failed on following ...
5 years, 9 months ago (2015-03-02 21:17:08 UTC) #33
cbentzel
On 2015/03/02 20:42:26, I haz the power (commit-bot) wrote: > Try jobs failed on following ...
5 years, 9 months ago (2015-03-02 21:17:10 UTC) #34
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/937743003/80001
5 years, 9 months ago (2015-03-02 21:26:38 UTC) #36
commit-bot: I haz the power
Committed patchset #5 (id:80001)
5 years, 9 months ago (2015-03-02 21:30:59 UTC) #37
commit-bot: I haz the power
5 years, 9 months ago (2015-03-02 21:31:49 UTC) #38
Message was sent while issue was closed.
Patchset 5 (id:??) landed as
https://crrev.com/3e740be5fa1026ae8b39d99f1180b7c39b9d4b12
Cr-Commit-Position: refs/heads/master@{#318766}

Powered by Google App Engine
This is Rietveld 408576698