From 1fcc80b5ae804d76551e72a6be415601c16fa9bb Mon Sep 17 00:00:00 2001 From: Nicola Fontana Date: Fri, 23 Jan 2015 23:21:52 +0100 Subject: [PATCH] CpmlExtents: correct bug in is_inside A covered test was failing because of a real error in the code: cpml_extents_is_inside() was using the size of the first extents for both the extents. --- src/cpml/cpml-extents.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/cpml/cpml-extents.c b/src/cpml/cpml-extents.c index c4718967..a2365012 100644 --- a/src/cpml/cpml-extents.c +++ b/src/cpml/cpml-extents.c @@ -207,8 +207,8 @@ cpml_extents_is_inside(const CpmlExtents *extents, const CpmlExtents *src) pe.x += extents->size.x; pe.y += extents->size.y; - ps.x += extents->size.x; - ps.y += extents->size.y; + ps.x += src->size.x; + ps.y += src->size.y; return ps.x <= pe.x && ps.y <= pe.y; } -- 2.11.4.GIT