From 6934a9623e0036bfd0d6f5e8d2f9f8553c8d4b56 Mon Sep 17 00:00:00 2001 From: Marcel Hollerbach Date: Mon, 23 Mar 2020 11:20:56 +0100 Subject: [PATCH] ector: fix pointer checking we want to check if the pointer is available, and not the value of the pointer. This fixes some "Jump depends on uninitialized value" messages from valgrind. --- src/lib/ector/software/ector_software_buffer.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/lib/ector/software/ector_software_buffer.c b/src/lib/ector/software/ector_software_buffer.c index 62dae2c50b..efaf5fefca 100644 --- a/src/lib/ector/software/ector_software_buffer.c +++ b/src/lib/ector/software/ector_software_buffer.c @@ -67,10 +67,10 @@ EOLIAN static Eina_Bool _ector_software_buffer_base_ector_buffer_pixels_get(Eo *obj EINA_UNUSED, Ector_Software_Buffer_Base_Data *pd, void **pixels, int* width, int* height, int* stride) { - if (*pixels) *pixels = pd->pixels.u8; - if (*width) *width = pd->generic->w; - if (*height) *height = pd->generic->h; - if (*stride) *stride = pd->stride; + if (pixels) *pixels = pd->pixels.u8; + if (width) *width = pd->generic->w; + if (height) *height = pd->generic->h; + if (stride) *stride = pd->stride; return pd->writable; }