Index: libcurl_http_fetcher.h |
diff --git a/libcurl_http_fetcher.h b/libcurl_http_fetcher.h |
index 3a50bda46e7ae2ce365f3661f926bc2cb4f2200f..b3ba518d5f6e865b447f5a08f7361e8f74844527 100644 |
--- a/libcurl_http_fetcher.h |
+++ b/libcurl_http_fetcher.h |
@@ -48,8 +48,8 @@ class LibcurlHttpFetcher : public HttpFetcher { |
// Begins the transfer if it hasn't already begun. |
virtual void BeginTransfer(const std::string& url); |
- // If the transfer is in progress, aborts the transfer early. |
- // The transfer cannot be resumed. |
+ // If the transfer is in progress, aborts the transfer early. The transfer |
+ // cannot be resumed. |
virtual void TerminateTransfer(); |
// Suspend the transfer by calling curl_easy_pause(CURLPAUSE_ALL). |
@@ -136,6 +136,11 @@ class LibcurlHttpFetcher : public HttpFetcher { |
// curl(m) handles, io_channels_, timeout_source_. |
void CleanUp(); |
+ // Force terminate the transfer. This will invoke the delegate's (if any) |
+ // TransferTerminated callback so, after returning, this fetcher instance may |
+ // be destroyed. |
+ void ForceTransferTermination(); |
+ |
// Returns whether or not the current network connection is considered |
// expensive. |
bool ConnectionIsExpensive() const; |