diff options
| author | Manos Pitsidianakis <manos.pitsidianakis@linaro.org> | 2023-11-21 11:38:39 +0200 |
|---|---|---|
| committer | Marc-André Lureau <marcandre.lureau@redhat.com> | 2023-11-21 14:38:14 +0400 |
| commit | e0c58720bfd8c0553f170b64717278b07438d2f5 (patch) | |
| tree | e5bc3cb650f97fe0045b8749af066e6655fcc81a /hw/core/loader.c | |
| parent | ff2a5bed5f28cc59b25de76cb90196329da6c1f4 (diff) | |
| download | focaccia-qemu-e0c58720bfd8c0553f170b64717278b07438d2f5.tar.gz focaccia-qemu-e0c58720bfd8c0553f170b64717278b07438d2f5.zip | |
ui/pixman-minimal.h: fix empty allocation
In the minimal pixman API stub that is used when the real pixman dependency is missing a NULL dereference happens when virtio-gpu-rutabaga allocates a pixman image with bits = NULL and rowstride_bytes = zero. A buffer of rowstride_bytes * height is allocated which is NULL. However, in that scenario pixman calculates a new stride value based on given width, height and format size. This commit adds a helper function that performs the same logic as pixman. Signed-off-by: Manos Pitsidianakis <manos.pitsidianakis@linaro.org> Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20231121093840.2121195-1-manos.pitsidianakis@linaro.org>
Diffstat (limited to 'hw/core/loader.c')
0 files changed, 0 insertions, 0 deletions