From b21a97294bc1dcda3eed1061f8a7306ad90c3838 Mon Sep 17 00:00:00 2001 From: Jim Evans Date: Tue, 19 Mar 2013 10:41:38 -0400 Subject: [PATCH] Updating logic in IE driver to correctly wait for the document. Fixes issue #5326. --- cpp/IEDriver/Browser.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cpp/IEDriver/Browser.cpp b/cpp/IEDriver/Browser.cpp index 9eb54abf9a004..101eaf6de97cb 100644 --- a/cpp/IEDriver/Browser.cpp +++ b/cpp/IEDriver/Browser.cpp @@ -413,7 +413,7 @@ bool Browser::Wait() { is_navigating = this->is_navigation_started_; CComPtr 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; }