mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-05-16 08:28:05 +02:00
Fix NULL dereference in active_edges_to_traps() provoked by
https://gitlab.freedesktop.org/poppler/poppler/-/issues/1579
This commit is contained in:
parent
7fd0cd0a9c
commit
7a15ba7284
1 changed files with 5 additions and 0 deletions
|
|
@ -468,6 +468,9 @@ active_edges_to_traps (sweep_line_t *sweep)
|
|||
edge_t *left, *right;
|
||||
int winding;
|
||||
|
||||
if (unlikely (pos == NULL))
|
||||
break;
|
||||
|
||||
left = pos;
|
||||
winding = left->dir;
|
||||
|
||||
|
|
@ -503,6 +506,8 @@ active_edges_to_traps (sweep_line_t *sweep)
|
|||
* boxes.
|
||||
*/
|
||||
winding += right->dir;
|
||||
if (unlikely (right->next == NULL))
|
||||
break;
|
||||
if (winding == 0 && right->x != right->next->x)
|
||||
break;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue