diff --git a/canvas.png b/canvas.png new file mode 100644 index 00000000000..d83232e20e1 Binary files /dev/null and b/canvas.png differ diff --git a/components/script/dom/imagedata.rs b/components/script/dom/imagedata.rs index 0909def3ca0..d11c7793484 100644 --- a/components/script/dom/imagedata.rs +++ b/components/script/dom/imagedata.rs @@ -114,12 +114,8 @@ impl ImageData { let len = width * height * 4; let cx = global.get_cx(); rooted!(in (*cx) let mut array = ptr::null_mut::()); - Uint8ClampedArray::create( - *cx, - CreateWith::Length(len as usize), - array.handle_mut(), - ) - .unwrap(); + Uint8ClampedArray::create(*cx, CreateWith::Length(len as usize), array.handle_mut()) + .unwrap(); (*imagedata).data.set(array.get()); Ok(reflect_dom_object(imagedata, global))