Skip to content

Commit

Permalink
Fail hard if node weights are not there
Browse files Browse the repository at this point in the history
  • Loading branch information
TheMarex committed Jan 21, 2016
1 parent 439eb9d commit 17f8e65
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/contractor/contractor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,13 @@ int Contractor::Run()
std::vector<EdgeWeight> node_weights;
std::string node_file_name = config.osrm_input_path.string() + ".enw";
if (util::deserializeVector(node_file_name, node_weights))
{
util::SimpleLogger().Write() << "Done reading node weights.";
}
else
util::SimpleLogger().Write() << "Failed reading node weights.";
{
throw util::exception("Failed reading node weights.");
}

util::DeallocatingVector<QueryEdge> contracted_edge_list;
ContractGraph(max_edge_id, edge_based_edge_list, contracted_edge_list, std::move(node_weights),
Expand Down

0 comments on commit 17f8e65

Please sign in to comment.