aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/engine/Edge.cpp6
-rw-r--r--src/engine/Machine.cpp3
2 files changed, 4 insertions, 5 deletions
diff --git a/src/engine/Edge.cpp b/src/engine/Edge.cpp
index 16bc202..1a7d236 100644
--- a/src/engine/Edge.cpp
+++ b/src/engine/Edge.cpp
@@ -40,11 +40,7 @@ Edge::write_state(Raul::RDFWriter& writer)
if (!src || !dst)
return;
- if (!src->id())
- src->set_id(writer.blank_id());
-
- if (!dst->id())
- dst->set_id(writer.blank_id());
+ assert(src->id() && dst->id());
writer.write(_id,
RdfId(RdfId::RESOURCE, "machina:tail"),
diff --git a/src/engine/Machine.cpp b/src/engine/Machine.cpp
index e88a78e..f76dd5c 100644
--- a/src/engine/Machine.cpp
+++ b/src/engine/Machine.cpp
@@ -244,6 +244,9 @@ Machine::write_state(Raul::RDFWriter& writer)
RdfId(RdfId::RESOURCE, "machina:node"),
(*n)->id());
}
+ }
+
+ for (Nodes::const_iterator n = _nodes.begin(); n != _nodes.end(); ++n) {
for (Node::Edges::const_iterator e = (*n)->outgoing_edges().begin();
e != (*n)->outgoing_edges().end(); ++e) {