From 89ea7caae9f92761556cbab2ec26a533554938b4 Mon Sep 17 00:00:00 2001 From: Marshall Greenblatt Date: Fri, 4 May 2012 18:34:12 +0000 Subject: [PATCH] Fix usage of ReadRawData return value in scheme handler implementation (issue #534). git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@617 5089003a-bbd8-11dd-ad1f-f1f9622dbc98 --- cef1/libcef/scheme_impl.cc | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/cef1/libcef/scheme_impl.cc b/cef1/libcef/scheme_impl.cc index b99ac5736..4d84143d1 100644 --- a/cef1/libcef/scheme_impl.cc +++ b/cef1/libcef/scheme_impl.cc @@ -498,9 +498,14 @@ class CefUrlRequestJob : public net::URLRequestJob { dest_ = NULL; dest_size_ = 0; + } else { + // All done. + job_->NotifyDone(URLRequestStatus()); } - } else { - // All done. + } else if (!job_->GetStatus().is_io_pending()) { + // Failed due to an error. + NOTREACHED() << + "ReadRawData returned false without setting IO as pending"; job_->NotifyDone(URLRequestStatus()); } }