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

Unified Diff: components/reading_list/ios/reading_list_model_impl.cc

Issue 2608913002: Handle invalid URLs in share extension. (Closed)
Patch Set: adding gambard as OWNER Created 3 years, 12 months 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 | « no previous file | ios/chrome/browser/share_extension/OWNERS » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/reading_list/ios/reading_list_model_impl.cc
diff --git a/components/reading_list/ios/reading_list_model_impl.cc b/components/reading_list/ios/reading_list_model_impl.cc
index fef295916b7f5c7d9a8387435f5f2c61205f756c..fa3a9bc2d126b5f78bc7b2bc5b0503efeff6e0de 100644
--- a/components/reading_list/ios/reading_list_model_impl.cc
+++ b/components/reading_list/ios/reading_list_model_impl.cc
@@ -292,6 +292,7 @@ const ReadingListEntry& ReadingListModelImpl::AddEntry(
const std::string& title) {
DCHECK(CalledOnValidThread());
DCHECK(loaded());
+ DCHECK(url.SchemeIsHTTPOrHTTPS());
RemoveEntryByURL(url);
std::string trimmedTitle(title);
« no previous file with comments | « no previous file | ios/chrome/browser/share_extension/OWNERS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698