summaryrefslogtreecommitdiff
path: root/lily/spanner.cc
diff options
context:
space:
mode:
authorHan-Wen Nienhuys <hanwen@xs4all.nl>2007-12-15 21:40:12 -0200
committerHan-Wen Nienhuys <hanwen@xs4all.nl>2007-12-15 21:40:12 -0200
commit5bd2d1080a904b9171ccf67520f5a172a8c3014b (patch)
tree18afdf8c2194400aa82e80c9f661ffadde66d271 /lily/spanner.cc
parent2f6ea490df6707b6524584d83fe699ffb9c183ad (diff)
Fix #527.
Don't generate rods for spanner without bounds.
Diffstat (limited to 'lily/spanner.cc')
-rw-r--r--lily/spanner.cc11
1 files changed, 7 insertions, 4 deletions
diff --git a/lily/spanner.cc b/lily/spanner.cc
index 53d6693654..b5b8a933a2 100644
--- a/lily/spanner.cc
+++ b/lily/spanner.cc
@@ -358,11 +358,14 @@ Spanner::set_spacing_rods (SCM smob)
{
Rod r;
Spanner *sp = dynamic_cast<Spanner *> (me);
-
-
System *root = get_root_system (me);
- vector<Item*> cols (root->broken_col_range (sp->get_bound (LEFT)->get_column (),
- sp->get_bound (RIGHT)->get_column ()));
+ Drul_array<Item*> bounds (sp->get_bound (LEFT),
+ sp->get_bound (RIGHT));
+ if (!bounds[LEFT] || !bounds[RIGHT])
+ return SCM_UNSPECIFIED;
+
+ vector<Item*> cols (root->broken_col_range (bounds[LEFT]->get_column (),
+ bounds[RIGHT]->get_column ()));
if (cols.size ())
{