$include_dir="/home/hyper-archives/boost-commit/include"; include("$include_dir/msg-header.inc") ?>
Subject: [Boost-commit] svn:boost r80961 - trunk/boost/graph
From: jewillco_at_[hidden]
Date: 2012-10-11 16:09:24
Author: jewillco
Date: 2012-10-11 16:09:23 EDT (Thu, 11 Oct 2012)
New Revision: 80961
URL: http://svn.boost.org/trac/boost/changeset/80961
Log:
Fixed for starting vertices other than 0; thanks to Morten Strandberg for the bug report
Text files modified: 
   trunk/boost/graph/metric_tsp_approx.hpp |     4 ++--                                    
   1 files changed, 2 insertions(+), 2 deletions(-)
Modified: trunk/boost/graph/metric_tsp_approx.hpp
==============================================================================
--- trunk/boost/graph/metric_tsp_approx.hpp	(original)
+++ trunk/boost/graph/metric_tsp_approx.hpp	2012-10-11 16:09:23 EDT (Thu, 11 Oct 2012)
@@ -216,7 +216,7 @@
         // Create tour using a preorder traversal of the mst
         vector<Node> tour;
         PreorderTraverser<Node, Tree> tvis(tour);
-        traverse_tree(0, t, tvis);
+        traverse_tree(indexmap[start], t, tvis);
 
         pair<GVItr, GVItr> g_verts(vertices(g));
         for(PreorderTraverser<Node, Tree>::const_iterator curr(tvis.begin());
@@ -228,7 +228,7 @@
         }
 
         // Connect back to the start of the tour
-        vis.visit_vertex(*g_verts.first, g);
+        vis.visit_vertex(start, g);
     }
 
     // Default tsp tour visitor that puts the tour in an OutputIterator