From 3a85d98f83388eba1d57b1d53a2d6fbca019583d Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Mon, 17 Mar 2003 00:52:16 +0000 Subject: [PATCH] fix an out-by-one error --- tools/qfvis/source/qfvis.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/qfvis/source/qfvis.c b/tools/qfvis/source/qfvis.c index 7869b545c..d5ad68a4b 100644 --- a/tools/qfvis/source/qfvis.c +++ b/tools/qfvis/source/qfvis.c @@ -391,7 +391,7 @@ ClusterFlow (int clusternum) totalvis += numvis; i = CompressRow (outbuffer, compressed); - cluster->visofs = visdata->size; + cluster->visofs = visdata->size; dstring_append (visdata, compressed, i); } @@ -464,7 +464,7 @@ CalcVis (void) ClusterFlow (i); for (i = 0; i < numrealleafs; i++) { - bsp->leafs[i].visofs = clusters[leafcluster[i]].visofs; + bsp->leafs[i + 1].visofs = clusters[leafcluster[i]].visofs; } if (options.verbosity >= 0) printf ("average clusters visible: %i\n", totalvis / portalclusters);