Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upassertion failed: rect.size.width >= Zero::zero() caused by layout::display_list::background::clip #23091
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I keep running into this assertion while fuzzing, so I decided to investigate.
One of the causes of this panic is the
background::clipfunction.Relevant parts of the backtrace:
I ran this example through a debugger, and it seems that
background::clipis receiving a zero-sized rectangle as the absolute_bounds, which causes a panic in euclid code.https://github.com/servo/servo/blob/master/components/layout/display_list/background.rs#L129
I believe the
clipfunction should either gracefully handle this case, or document the panic and pass the blame to the caller.Full backtrace
This is another example I reduced, I haven't ran this one through the debugger but the backtrace is similar.
Relevant parts:
Full backtrace