diff options
author | ericroman@google.com <ericroman@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-17 02:11:03 +0000 |
---|---|---|
committer | ericroman@google.com <ericroman@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-06-17 02:11:03 +0000 |
commit | eb255d3bd77fa891cd909d5779763a3e028759d2 (patch) | |
tree | d20650c59eb2150f73f27173e0325a05fa288836 /net/base/host_resolver.h | |
parent | c8220644056dfdb2d48f5d00578888a00ca02fe7 (diff) | |
download | chromium_src-eb255d3bd77fa891cd909d5779763a3e028759d2.zip chromium_src-eb255d3bd77fa891cd909d5779763a3e028759d2.tar.gz chromium_src-eb255d3bd77fa891cd909d5779763a3e028759d2.tar.bz2 |
Re-land another subset of r18520.
This particular subset should be a no-op: It adds an unused interface method (OnResolutionCancelled), and an unused test (CancelObserver), and lastly renames Cancel --> MarkAsCanceled().
The code in "dns_global.cc" is also unused since it is unreachable.
The original code review that this belongs to is:<http://codereview.chromium.org/125171>. (BUG=14138)
The original was backed out because of a valgrind linux error (BUG=14218), so I am now re-landing in smaller chunks to identify where the problem resides.
Review URL: http://codereview.chromium.org/126253
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@18581 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/base/host_resolver.h')
-rw-r--r-- | net/base/host_resolver.h | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/net/base/host_resolver.h b/net/base/host_resolver.h index 34c803f..6e2add7 100644 --- a/net/base/host_resolver.h +++ b/net/base/host_resolver.h @@ -106,13 +106,18 @@ class HostResolver { // Called at the start of HostResolver::Resolve(). |id| is a unique number // given to the request, so it can be matched up with a corresponding call - // to OnFinishResolutionWithStatus(). + // to OnFinishResolutionWithStatus() or OnCancelResolution(). virtual void OnStartResolution(int id, const RequestInfo& info) = 0; // Called on completion of request |id|. Note that if the request was - // cancelled, OnFinishResolutionWithStatus() will not be called. + // cancelled, OnCancelResolution() will be called instead. virtual void OnFinishResolutionWithStatus(int id, bool was_resolved, const RequestInfo& info) = 0; + + // Called when request |id| has been cancelled. A request is "cancelled" + // if either the HostResolver is destroyed while a resolution is in + // progress, or HostResolver::CancelRequest() is called. + virtual void OnCancelResolution(int id, const RequestInfo& info) = 0; }; // Creates a HostResolver that caches up to |max_cache_entries| for @@ -175,11 +180,11 @@ class HostResolver { // Callback for when |job| has completed with |error| and |addrlist|. void OnJobComplete(Job* job, int error, const AddressList& addrlist); - // Notify all obsevers of the start of a resolve request. + // Notify all observers of the start of a resolve request. void NotifyObserversStartRequest(int request_id, const RequestInfo& info); - // Notify all obsevers of the completion of a resolve request. + // Notify all observers of the completion of a resolve request. void NotifyObserversFinishRequest(int request_id, const RequestInfo& info, int error); |