This is an automated email from the git hooks/post-receive script.

git pushed a commit to reference refs/pull/287/head
in repository efl.

View the commit online.

commit fd6b2cb9a7a2090a244233abdd953afb6deb146e
Author: Cedric BAIL <[email protected]>
AuthorDate: Sat Nov 28 21:47:49 2026 -0600

    evas/map: copy only the prepared span lines
    
    evas_common_map_rgba_do() copied two more span lines than
    evas_common_map_rgba_prepare() allocates, reading past the end of them.
    valgrind shows it on the evas_map_prepare test. Nothing drawn reads the
    extra lines.
    
    With the lines sized exactly, a clip that leaves none to draw has to
    return early.
    
    Co-Authored-By: Claude Opus 5.5 <[email protected]>
---
 src/lib/evas/common/evas_map_image_internal.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/lib/evas/common/evas_map_image_internal.c b/src/lib/evas/common/evas_map_image_internal.c
index 84c7ab0f03..ffafba937e 100644
--- a/src/lib/evas/common/evas_map_image_internal.c
+++ b/src/lib/evas/common/evas_map_image_internal.c
@@ -199,6 +199,8 @@ FUNC_NAME_DO(RGBA_Image *src, RGBA_Image *dst,
    if (ms->yend >= (cy + ch)) yend = (cy + ch) - 1;
    else yend = ms->yend;
 
+   if ((!ms->spans) || (yend < ystart)) return;
+
    // get some source image information
    sp = src->image.data;
    sw = src->cache_entry.w;
@@ -218,9 +220,9 @@ FUNC_NAME_DO(RGBA_Image *src, RGBA_Image *dst,
    da = dst->cache_entry.flags.alpha;
 
    // allocate some s to hold out span list
-   spans = alloca((yend - ystart + 3) * sizeof(Line));
+   spans = alloca((yend - ystart + 1) * sizeof(Line));
    memcpy(spans, &ms->spans[ystart - ms->ystart],
-          (yend - ystart + 3) * sizeof(Line));
+          (yend - ystart + 1) * sizeof(Line));
    _clip_spans(spans, ystart, yend, cx, cw, EINA_TRUE, persp);
 
    // if operation is solid, bypass buf and draw func and draw direct to dst

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.

Reply via email to