summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/los.cc
diff options
context:
space:
mode:
authorRobert Vollmert <rvollmert@gmx.net>2009-10-09 10:15:39 +0200
committerRobert Vollmert <rvollmert@gmx.net>2009-10-09 10:15:39 +0200
commit477b8798b39a01bf4a73697eefe0ae131a12d47d (patch)
tree7bde0d5202af26946bf0b3d7fca3b767291332df /crawl-ref/source/los.cc
parentf54c573cd027fc1c86e206ada722ce8a76525f4a (diff)
downloadcrawl-ref-477b8798b39a01bf4a73697eefe0ae131a12d47d.tar.gz
crawl-ref-477b8798b39a01bf4a73697eefe0ae131a12d47d.zip
Initialize ray.full_idx to -1 and remove outdated(?) valgrind intialization lines.
Diffstat (limited to 'crawl-ref/source/los.cc')
-rw-r--r--crawl-ref/source/los.cc4
1 files changed, 1 insertions, 3 deletions
diff --git a/crawl-ref/source/los.cc b/crawl-ref/source/los.cc
index 77b81d240c..f7a77bd82f 100644
--- a/crawl-ref/source/los.cc
+++ b/crawl-ref/source/los.cc
@@ -202,7 +202,7 @@ static std::vector<int> _find_nonduped_cellrays()
static bool _register_ray( double accx, double accy, double slope )
{
int xpos[LOS_MAX_RANGE * 2 + 1], ypos[LOS_MAX_RANGE * 2 + 1];
- int raylen = shoot_ray( accx, accy, slope, LOS_MAX_RANGE, xpos, ypos );
+ int raylen = shoot_ray(accx, accy, slope, LOS_MAX_RANGE, xpos, ypos);
// Early out if ray already exists.
if (_is_duplicate_ray(raylen, xpos, ypos))
@@ -644,8 +644,6 @@ int num_feats_between(const coord_def& source, const coord_def& target,
int count = 0;
int max_dist = grid_distance(source, target);
- ray.fullray_idx = -1; // to quiet valgrind
-
// We don't need to find the shortest beam, any beam will suffice.
find_ray( source, target, true, ray, 0, false, true );