servo: Merge #12463 - Replace any errors caused by content-provided URLs by warnings (from asajeffrey:url-errors-should-be-warnings); r=Ms2ger
authorAlan Jeffrey <ajeffrey@mozilla.com>
Fri, 15 Jul 2016 08:36:47 -0700
changeset 339299 4927f334e679b21870815bae58a51edc50106c96
parent 339298 d0becf5b5cb8829ec2817ecf26c3b3f68614057d
child 339300 fe21c09a9d2329676f267754758ae954af79b03f
push id31307
push usergszorc@mozilla.com
push dateSat, 04 Feb 2017 00:59:06 +0000
treeherdermozilla-central@94079d43835f [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersMs2ger
servo: Merge #12463 - Replace any errors caused by content-provided URLs by warnings (from asajeffrey:url-errors-should-be-warnings); r=Ms2ger <!-- Please describe your changes on the following line: --> --- <!-- Thank you for contributing to Servo! Please replace each `[ ]` by `[X]` when the step is complete, and replace `__` with appropriate data: --> - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes do not require tests because we don't test error generation <!-- Pull requests that do not address these steps are welcome, but they will require additional verification as part of the review process. --> Source-Repo: https://github.com/servo/servo Source-Revision: 6f3967b00490c750853ab3b56c54418b321d11a3
servo/components/compositing/compositor.rs
servo/components/script/dom/htmlscriptelement.rs
--- a/servo/components/compositing/compositor.rs
+++ b/servo/components/compositing/compositor.rs
@@ -1398,17 +1398,17 @@ impl<Window: WindowMethods> IOCompositor
                 let msg = match self.scene.root {
                     Some(ref layer) => ConstellationMsg::LoadUrl(layer.pipeline_id(), LoadData::new(url, None, None)),
                     None => ConstellationMsg::InitLoadUrl(url)
                 };
                 if let Err(e) = self.constellation_chan.send(msg) {
                     warn!("Sending load url to constellation failed ({}).", e);
                 }
             },
-            Err(e) => error!("Parsing URL {} failed ({}).", url_string, e),
+            Err(e) => warn!("Parsing URL {} failed ({}).", url_string, e),
         }
     }
 
     fn on_mouse_window_event_class(&mut self, mouse_window_event: MouseWindowEvent) {
         if opts::get().convert_mouse_to_touch {
             match mouse_window_event {
                 MouseWindowEvent::Click(_, _) => {}
                 MouseWindowEvent::MouseDown(_, p) => self.on_touch_down(TouchId(0), p),
--- a/servo/components/script/dom/htmlscriptelement.rs
+++ b/servo/components/script/dom/htmlscriptelement.rs
@@ -323,17 +323,17 @@ impl HTMLScriptElement {
                 if src.is_empty() {
                     self.queue_error_event();
                     return NextParserState::Continue;
                 }
 
                 // Step 18.4-18.5.
                 let url = match base_url.join(&src) {
                     Err(_) => {
-                        error!("error parsing URL for script {}", &**src);
+                        warn!("error parsing URL for script {}", &**src);
                         self.queue_error_event();
                         return NextParserState::Continue;
                     }
                     Ok(url) => url,
                 };
 
                 // Step 18.6.
                 fetch_a_classic_script(self, url, encoding);
@@ -409,17 +409,17 @@ impl HTMLScriptElement {
         }
 
         let load = self.load.borrow_mut().take().unwrap();
 
         // Step 2.
         let (source, external, url) = match load {
             // Step 2.a.
             ScriptOrigin::External(Err(e)) => {
-                error!("error loading script {:?}", e);
+                warn!("error loading script {:?}", e);
                 self.dispatch_error_event();
                 return;
             }
 
             // Step 2.b.1.a.
             ScriptOrigin::External(Ok((text, url))) => {
                 debug!("loading external script, url = {}", url);
                 (DOMString::from(text), true, url)