From 4a402480cac86ffa8aab68d54af9cf88fae33401 Mon Sep 17 00:00:00 2001 From: Christian Gmeiner Date: Wed, 23 Sep 2009 11:14:21 +0200 Subject: check in cSpuRegion::addIndex if index was already added --- spuregion.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/spuregion.c b/spuregion.c index f3a8906..b2a6526 100644 --- a/spuregion.c +++ b/spuregion.c @@ -62,6 +62,10 @@ bool cSpuRegion::addIndex(tIndex idx) { sSection *sec = §ions[usedSections]; + if (containsIndex(idx)) { + return true; + } + if (sec->usedColors == MAX_COLORS) { return false; } -- cgit v1.2.3