Skip to content

Commit

Permalink
Add missing DCHECK to validate HR.
Browse files Browse the repository at this point in the history
This issue was found by a linter.

The value of 'hr' is ignored. Probably a nice idea to validate the CreateInstance success.

R=amit@chromium.org,tommi@chromium.org
BUG=

Review URL: https://chromiumcodereview.appspot.com/21948002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@218662 0039d316-1c4b-4281-b951-d872f2087c98
  • Loading branch information
etienneb@chromium.org committed Aug 21, 2013
1 parent aaa1c6e commit 6504c08
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions chrome_frame/urlmon_bind_status_callback.cc
Original file line number Diff line number Diff line change
Expand Up @@ -320,6 +320,8 @@ STDMETHODIMP BSCBStorageBind::OnStopBinding(HRESULT hresult, LPCWSTR error) {
ExceptionBarrier barrier;

HRESULT hr = MayPlayBack(BSCF_LASTDATANOTIFICATION);
if (FAILED(hr))
return hr;
hr = CallbackImpl::OnStopBinding(hresult, error);
ReleaseBind();
return hr;
Expand Down
1 change: 1 addition & 0 deletions chrome_frame/urlmon_moniker.cc
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,7 @@ HRESULT MonikerPatch::BindToStorage(IMoniker_BindToStorage_Fn original,
CComObject<BSCBStorageBind>* callback = NULL;
if (ShouldWrapCallback(me, iid, bind_ctx)) {
hr = CComObject<BSCBStorageBind>::CreateInstance(&callback);
DCHECK(SUCCEEDED(hr));
auto_release_callback = callback;
DCHECK_EQ(callback->m_dwRef, 1);
hr = callback->Initialize(me, bind_ctx);
Expand Down

0 comments on commit 6504c08

Please sign in to comment.