From 8196385438caa45aef6ddd2dbae26a431d704268 Mon Sep 17 00:00:00 2001 From: Giles Bathgate Date: Sun, 14 Aug 2011 20:57:46 +0100 Subject: Fix for crash caused by 0-sized square as reported by chrysn. diff --git a/src/primitives.cc b/src/primitives.cc index 5180c16..45b2da3 100644 --- a/src/primitives.cc +++ b/src/primitives.cc @@ -434,7 +434,7 @@ sphere_next_r2: } } - if (type == SQUARE) + if (type == SQUARE && x > 0 && y > 0) { double x1, x2, y1, y2; if (center) { -- cgit v0.10.1