Internals: Add VL_DO_CLEAR delete protections. No functional change intended.

This commit is contained in:
Wilson Snyder
2020-01-18 10:29:49 -05:00
parent 2f4954ca68
commit 09199f79a6
23 changed files with 57 additions and 48 deletions
+1 -3
View File
@@ -150,9 +150,7 @@ public:
V3GraphEdge* deletep = NULL;
for (V3GraphEdge* edgep = vxp->outBeginp();
edgep; edgep = edgep->outNextp()) {
if (deletep) {
deletep->unlinkDelete(); deletep = NULL;
}
if (deletep) VL_DO_CLEAR(deletep->unlinkDelete(), deletep = NULL);
// It should be safe to modify the graph, despite using
// the GraphPathChecker, as none of the modifications will
// change what can be reached from what, nor should they