Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(279)

Unified Diff: pdf/pdfium/pdfium_engine.cc

Issue 2455663004: Add test to ensure that URLs that redirect inside the PDF plugin fail to load (Closed)
Patch Set: . Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pdf/out_of_process_instance.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pdf/pdfium/pdfium_engine.cc
diff --git a/pdf/pdfium/pdfium_engine.cc b/pdf/pdfium/pdfium_engine.cc
index 475d56933053765ad2f460b8ca1d7a89df84a095..39414d1fe2c55bbea2e6b72876419322674e87b3 100644
--- a/pdf/pdfium/pdfium_engine.cc
+++ b/pdf/pdfium/pdfium_engine.cc
@@ -1106,7 +1106,10 @@ void PDFiumEngine::OnDocumentComplete() {
}
void PDFiumEngine::OnDocumentCanceled() {
- OnDocumentComplete();
+ if (visible_pages_.empty())
+ client_->DocumentLoadFailed();
+ else
+ OnDocumentComplete();
}
void PDFiumEngine::CancelBrowserDownload() {
« no previous file with comments | « pdf/out_of_process_instance.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698