summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorbulia byak <buliabyak@gmail.com>2009-10-04 15:20:53 +0000
committerbuliabyak <buliabyak@users.sourceforge.net>2009-10-04 15:20:53 +0000
commit6339ecbc3f9c1a8925a9bfe1fef9fef2da9f474d (patch)
tree951c30baffbf9d519b21964fe9aae33841346a9e /src
parentJapanese tutorials (SVG files) and interface translation updates by Masato HA... (diff)
downloadinkscape-6339ecbc3f9c1a8925a9bfe1fef9fef2da9f474d.tar.gz
inkscape-6339ecbc3f9c1a8925a9bfe1fef9fef2da9f474d.zip
Diederik's patch for crash bug 441255
(bzr r8709)
Diffstat (limited to 'src')
-rw-r--r--src/seltrans.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/seltrans.cpp b/src/seltrans.cpp
index 1087ec7b5..708ee4b09 100644
--- a/src/seltrans.cpp
+++ b/src/seltrans.cpp
@@ -408,8 +408,9 @@ void Inkscape::SelTrans::grab(Geom::Point const &p, gdouble x, gdouble y, bool s
// Optionally, show the snap source
if (!(_state == STATE_ROTATE && x != 0.5 && y != 0.5)) { // but not when we're dragging a rotation handle, because that won't snap
// Now either _bbox_points or _snap_points has a single element, the other one has zero..... or both have zero elements
- g_assert((_snap_points.size() + _bbox_points.size() + _bbox_points_for_translating.size()) == 1);
- if (m.snapprefs.getSnapEnabledGlobally()) {
+ if ((_snap_points.size() + _bbox_points.size() + _bbox_points_for_translating.size()) > 1) {
+ g_warning("too many snap sources to display, please fix this");
+ } else if (m.snapprefs.getSnapEnabledGlobally()) {
if (_bbox_points.size() == 1) {
_desktop->snapindicator->set_new_snapsource(_bbox_points.at(0));
} else if (_bbox_points_for_translating.size() == 1) {