diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2014-11-23 23:36:49 +0000 |
|---|---|---|
| committer | Jabiertxof <jtx@jtx.marker.es> | 2014-11-23 23:36:49 +0000 |
| commit | 0969085ddf607a7a98cf7fd6d9b10da5fbebe62d (patch) | |
| tree | 59b2bc9ed3412ab2de4c703ef30342dfe2401704 /src/libavoid | |
| parent | refactor from lastApplied (diff) | |
| parent | Fixed a bug pointed by suv running from comand line, also removed another des... (diff) | |
| download | inkscape-0969085ddf607a7a98cf7fd6d9b10da5fbebe62d.tar.gz inkscape-0969085ddf607a7a98cf7fd6d9b10da5fbebe62d.zip | |
fixing to trunk
(bzr r12588.1.34)
Diffstat (limited to 'src/libavoid')
| -rw-r--r-- | src/libavoid/connector.cpp | 23 |
1 files changed, 15 insertions, 8 deletions
diff --git a/src/libavoid/connector.cpp b/src/libavoid/connector.cpp index 8dcb66f2d..40ded7498 100644 --- a/src/libavoid/connector.cpp +++ b/src/libavoid/connector.cpp @@ -442,11 +442,11 @@ void ConnRef::makeActive(void) void ConnRef::makeInactive(void) { - COLA_ASSERT(_active); - - // Remove from connRefs list. - _router->connRefs.erase(_pos); - _active = false; + if (_active) { + // Remove from connRefs list. + _router->connRefs.erase(_pos); + _active = false; + } } @@ -553,8 +553,12 @@ void ConnRef::unInitialise(void) void ConnRef::removeFromGraph(void) { - _srcVert->removeFromGraph(); - _dstVert->removeFromGraph(); + if (_srcVert) { + _srcVert->removeFromGraph(); + } + if (_dstVert) { + _dstVert->removeFromGraph(); + } } @@ -841,7 +845,10 @@ bool ConnRef::generatePath(void) break; } // Check we don't have an apparent infinite connector path. - COLA_ASSERT(pathlen < 200); +//#ifdef PATHDEBUG + db_printf("Path length: %i\n", pathlen); +//#endif + COLA_ASSERT(pathlen < 10000); } std::vector<Point> path(pathlen); |
