Skip to content

Commit

Permalink
Updating logic in IE driver to correctly wait for the document.
Browse files Browse the repository at this point in the history
Fixes issue SeleniumHQ#5326.
  • Loading branch information
jimevans authored and detro committed Mar 19, 2013
1 parent 428b321 commit b21a972
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cpp/IEDriver/Browser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,7 @@ bool Browser::Wait() {
is_navigating = this->is_navigation_started_;
CComPtr<IDispatch> document_dispatch;
hr = this->browser_->get_Document(&document_dispatch);
if (is_navigating && FAILED(hr) && !document_dispatch) {
if (is_navigating || FAILED(hr) || !document_dispatch) {
LOG(DEBUG) << "Get Document failed.";
return false;
}
Expand Down

0 comments on commit b21a972

Please sign in to comment.