mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
stylo: handle unresolved url value gracefully
This commit is contained in:
parent
fed488cd01
commit
09ce1320e9
3 changed files with 21 additions and 8 deletions
|
@ -133,7 +133,9 @@ impl nsStyleImage {
|
|||
self.set_gradient(gradient)
|
||||
},
|
||||
Image::Url(ref url) if with_url => {
|
||||
let (ptr, len) = url.as_slice_components();
|
||||
let (ptr, len) = match url.as_slice_components() {
|
||||
Ok(value) | Err(value) => value
|
||||
};
|
||||
let extra_data = url.extra_data();
|
||||
unsafe {
|
||||
Gecko_SetUrlImageValue(self,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue