summaryrefslogtreecommitdiffstats
path: root/chrome_frame/urlmon_url_request.cc
diff options
context:
space:
mode:
authorstoyan@chromium.org <stoyan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-10 23:00:21 +0000
committerstoyan@chromium.org <stoyan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-10 23:00:21 +0000
commitb647cf88f396b6d60aaa7f2206d37b3a9a2e4a50 (patch)
treef99d3194b0ba4a082aec0909a4f14e9c8b107e63 /chrome_frame/urlmon_url_request.cc
parent0cda900cf8d2d0e34eacc5437b9fc7a4375328f5 (diff)
downloadchromium_src-b647cf88f396b6d60aaa7f2206d37b3a9a2e4a50.zip
chromium_src-b647cf88f396b6d60aaa7f2206d37b3a9a2e4a50.tar.gz
chromium_src-b647cf88f396b6d60aaa7f2206d37b3a9a2e4a50.tar.bz2
Review URL: http://codereview.chromium.org/600032
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38692 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame/urlmon_url_request.cc')
-rw-r--r--chrome_frame/urlmon_url_request.cc9
1 files changed, 9 insertions, 0 deletions
diff --git a/chrome_frame/urlmon_url_request.cc b/chrome_frame/urlmon_url_request.cc
index c03b3f0..393b193 100644
--- a/chrome_frame/urlmon_url_request.cc
+++ b/chrome_frame/urlmon_url_request.cc
@@ -226,6 +226,15 @@ STDMETHODIMP UrlmonUrlRequest::OnStopBinding(HRESULT result, LPCWSTR error) {
return S_OK;
}
+ // We have no data, and no pending read request from Chrome.
+ // Wait until Chrome issue a read request and then send error/success code.
+ // The network policy in Chrome network is that error/end_of_stream should
+ // be returned only as a result of read (or start) request.
+ if (pending_read_size_ == 0) {
+ ReleaseBindings();
+ return S_OK;
+ }
+
NotifyDelegateAndDie();
return S_OK;
}