summaryrefslogtreecommitdiffstats
path: root/src/2geom/nearest-point.cpp
diff options
context:
space:
mode:
authorJabier Arraiza Cenoz <jabier.arraiza@marker.es>2014-04-01 17:00:00 +0000
committerJabiertxof <jtx@jtx.marker.es>2014-04-01 17:00:00 +0000
commit208ccdf9782984702f79b8ba416e67dd1e2c2dfa (patch)
tree79d15123aa526c49c6386db6245fbfc6b7a63eaf /src/2geom/nearest-point.cpp
parentupdate to trunk (diff)
parentpartial 2geom update: (diff)
downloadinkscape-208ccdf9782984702f79b8ba416e67dd1e2c2dfa.tar.gz
inkscape-208ccdf9782984702f79b8ba416e67dd1e2c2dfa.zip
update to trunk
(bzr r12588.1.32)
Diffstat (limited to 'src/2geom/nearest-point.cpp')
-rw-r--r--src/2geom/nearest-point.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/2geom/nearest-point.cpp b/src/2geom/nearest-point.cpp
index 68a863434..c5dfc133c 100644
--- a/src/2geom/nearest-point.cpp
+++ b/src/2geom/nearest-point.cpp
@@ -66,10 +66,9 @@ double nearest_point( Point const& p,
double closest = from;
double min_dist_sq = L2sq(c(from) - p);
- double distsq;
- for ( unsigned int i = 0; i < zeros.size(); ++i )
+ for ( size_t i = 0; i < zeros.size(); ++i )
{
- distsq = L2sq(c(zeros[i]) - p);
+ double distsq = L2sq(c(zeros[i]) - p);
if ( min_dist_sq > L2sq(c(zeros[i]) - p) )
{
closest = zeros[i];