Commit 3c64c67b authored by Tiago Peixoto's avatar Tiago Peixoto
Browse files

Fix bug in graphml.cpp with non-canonical edge ids

parent 21c38be9
......@@ -314,11 +314,12 @@ void build_stream
}
boost::python::tuple GraphInterface::ReadFromFile(string file, boost::python::object pfile,
string format,
boost::python::list ignore_vp,
boost::python::list ignore_ep,
boost::python::list ignore_gp)
boost::python::tuple GraphInterface::ReadFromFile(string file,
boost::python::object pfile,
string format,
boost::python::list ignore_vp,
boost::python::list ignore_ep,
boost::python::list ignore_gp)
{
if (format != "dot" && format != "xml" && format != "gml")
throw ValueException("error reading from file '" + file +
......@@ -345,7 +346,7 @@ boost::python::tuple GraphInterface::ReadFromFile(string file, boost::python::ob
if (format == "dot")
_directed = read_graphviz(stream, *_mg, dp, "vertex_name", true,
ivp, iep, igp);
ivp, iep, igp);
else if (format == "xml")
_directed = read_graphml(stream, *_mg, dp, true, true, true,
ivp, iep, igp);
......
......@@ -35,8 +35,11 @@ class graphml_reader
{
public:
graphml_reader(mutate_graph& g, bool integer_vertices, bool store_ids)
: m_g(g), m_canonical_vertices(false),
m_integer_vertices(integer_vertices), m_store_ids(store_ids) { }
: m_g(g),
m_canonical_vertices(false),
m_canonical_edges(false),
m_integer_vertices(integer_vertices),
m_store_ids(store_ids) { }
void run(std::istream& in)
{
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment