]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/rod.cc
remove ly_scm2str0.
[lilypond.git] / lily / rod.cc
index a10ba753db70694b2b1b16868253bccb88bef1b8..f86fc4e112bcf363035404bb0d9cb7e217d60409 100644 (file)
@@ -3,7 +3,7 @@
   
   source file of the GNU LilyPond music typesetter
   
-  (c) 1998--2003 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+  (c) 1998--2004 Han-Wen Nienhuys <hanwen@cs.uu.nl>
   
  */
 #include "rod.hh"
@@ -23,6 +23,10 @@ Rod::Rod ()
 void
 Rod::columnize ()
 {
+  if (!item_l_drul_[LEFT]
+      || !item_l_drul_[RIGHT])
+    return ;
+  
   Direction d = LEFT;
   do {
     Paper_column * pc = item_l_drul_[d]->get_column ();
@@ -36,9 +40,10 @@ void
 Rod::add_to_cols ()
 {
   columnize ();
-  if (item_l_drul_[LEFT] != item_l_drul_[RIGHT])
+  if (item_l_drul_[LEFT] != item_l_drul_[RIGHT]
+      && item_l_drul_[LEFT] && item_l_drul_[RIGHT])
     Spaceable_grob::add_rod (item_l_drul_[LEFT],
-                               item_l_drul_[RIGHT],
-                               distance_);
+                            item_l_drul_[RIGHT],
+                            distance_);
 }