Dont leak ownership in extractor::files

This commit is contained in:
Patrick Niklaus
2017-04-05 00:11:39 +00:00
committed by Patrick Niklaus
parent 0072bf0c59
commit 446c865415
4 changed files with 55 additions and 33 deletions
+1 -2
View File
@@ -299,8 +299,7 @@ int Extractor::run(ScriptingEnvironment &scripting_environment)
TIMER_STOP(rtree);
util::Log() << "Writing node map ...";
files::writeNodes<storage::Ownership::Container>(
config.node_output_path, coordinates, osm_node_ids);
files::writeNodes(config.node_output_path, coordinates, osm_node_ids);
WriteEdgeBasedGraph(config.edge_graph_output_path, max_edge_id, edge_based_edge_list);
+2 -3
View File
@@ -566,7 +566,7 @@ void Storage::PopulateData(const DataLayout &layout, char *memory_ptr)
util::vector_view<extractor::guidance::TurnLaneType::Mask> masks(
masks_ptr, layout.num_entries[storage::DataLayout::LANE_DESCRIPTION_MASKS]);
extractor::files::readTurnLaneDescriptions<storage::Ownership::View>(
extractor::files::readTurnLaneDescriptions(
config.turn_lane_description_path, offsets, masks);
}
@@ -695,8 +695,7 @@ void Storage::PopulateData(const DataLayout &layout, char *memory_ptr)
util::PackedVectorView<OSMNodeID> osm_node_ids;
osm_node_ids.reset(osmnodeid_ptr, layout.num_entries[DataLayout::OSM_NODE_ID_LIST]);
extractor::files::readNodes<storage::Ownership::View>(
config.nodes_data_path, coordinates, osm_node_ids);
extractor::files::readNodes(config.nodes_data_path, coordinates, osm_node_ids);
}
// load turn weight penalties