mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-05-06 05:48:00 +02:00
Fix out of bound access in struct pattern->type
The pattern structure is hardcoded to hold 7 elements, yet the pattern_names array in cairo-surface-observer.c is initialized with 8 strings. This causes a crash in print_array at line 1587 when it tries to access the 8th member. Hence changed the 'type' array from type[7] to type[8] to avoid out of bound access. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=91266 Signed-off-by: Ashim <ashim.shah@samsung.com> Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>
This commit is contained in:
parent
ad45e8f99f
commit
498fc2fbe3
1 changed files with 1 additions and 1 deletions
|
|
@ -62,7 +62,7 @@ struct extents {
|
|||
};
|
||||
|
||||
struct pattern {
|
||||
unsigned int type[7]; /* native/record/other surface/gradients */
|
||||
unsigned int type[8]; /* native/record/other surface/gradients */
|
||||
};
|
||||
|
||||
struct path {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue