Menu

#1173 Segfault with showFirstLength/showLastLength when skipBars is set

Verified
nobody
None
Defect
2010-10-26
2010-07-05
Anonymous
No

Originally created by: *anonymous

Originally created by: brownian.box@gmail.com

Reported by James Lowe:
http://lists.gnu.org/archive/html/bug-lilypond/2010-07/msg00012.html
(there is some discussion too)

%-----------8<-------------------------
\version "2.13.26"  % 2.12.3 crashes too

MusicOne = {
  \time 3/4
    \compressFullBarRests
    [r2].*11 \bar "||"
}

showLastLength = [r1]*2

\score {
  \new Staff {
    \MusicOne
  }         
}
%-----------8<-------------------------

This gives:

%-----------8<-------------------------
$ LANG=C lilypond sample.ly
GNU LilyPond 2.13.26
Processing `./sample.ly'
Parsing...
Interpreting music...
Preprocessing graphical objects...
Finding the ideal number of pages...
Fitting music on 1 page...
Drawing systems...
././sample.ly:6:4: programming error: Spanner `MultiMeasureRest' is not fully contained in parent spanner. Ignoring orphaned part
   
    [r2].*11 \bar "||"
Segmentation fault

Discussion

  • Google Importer

    Google Importer - 2010-07-07

    Originally posted by: n.putt...@gmail.com

    The presence of \score is unimportant here.

    showLastLength = [r1]

    {
      \time 3/4
      \compressFullBarRests
      [r2].*2
    }

    Summary: LilyPond crash when using showLastLength with \compressFullBarRests

     
  • Google Importer

    Google Importer - 2010-07-08

    Originally posted by: pnorcks@gmail.com

    Also note that no segfault occurs when the multi-measure rest "length" agrees with the time signature:

    showLastLength = [r2].

    {
      \time 3/4
      \compressFullBarRests
      [r2].*2
    }

     
  • Google Importer

    Google Importer - 2010-07-08

    Originally posted by: pnorcks@gmail.com

    That was probably an obvious comment.  I don't really use showLastLength that often... :)

     
  • Google Importer

    Google Importer - 2010-07-09

    Originally posted by: pkx1...@hotmail.com

    Just to re-itterate from the email thread.

    In cases where you use ShowLastLength for a score that has multiple scores in it and that all have different time signatures then this can be a problem.

    What I found specifically (to give this context) was that if I used [r2]. then it didn't crash on ANY time sig that was not necessairly matching (such as 4/4 or 2/2) I got odd output but no unexpected errors, but if I used [r1] it always crashed when one of the scores was 3/4. I hadn't experimented with any other time sigs

     
  • Google Importer

    Google Importer - 2010-08-04

    Originally posted by: n.putt...@gmail.com

    Mike Solomon has started work on this: http://codereview.appspot.com/1741060/show

    Labels: Patch
    Status: Started

     
  • Google Importer

    Google Importer - 2010-08-04

    Originally posted by: n.putt...@gmail.com

    (No comment was entered for this change.)

    Summary: LilyPond crash when using showFirstLength/showLastLength with \compressFullBarRests

     
  • Google Importer

    Google Importer - 2010-09-21

    Originally posted by: Carl.D.S...@gmail.com

    So what is the status of this fix?  At least part of the latest patch appears to have been applied to origin.

    Neil sent out a rebased patch in a mail to a few of us (Mike, Graham, me).  Is that patch considered a push candidate?

    Should a new issue be raised on Rietveld with Neil's latest patch?

    This is the *last* critical issue remaining (except the web, of course, which won't be fixed until we go to 2.14)

     
  • Google Importer

    Google Importer - 2010-09-22

    Originally posted by: percival.music.ca@gmail.com

    slight correction: I'm going ahead with the alpha test now, and then I'm switching web.  So rather: this is the last critical issue remaining before we can have a release candidate and begin the two-week waiting period.

    I'll send an explanation of the current release process plan to -devel once .34 is uploaded; I will accept objections and possibly modify the plans.

     
  • Google Importer

    Google Importer - 2010-10-17

    Originally posted by: v.villenave

    [Oops. I sent my comment before it was complete.]

    I've been trying to review Mike's patch; it looks pretty good to me but as Neil pointed out is does come with a cost in terms of calculation, and solving this specific issue is out of my depth.

    However, one simple workaround (however inelegant) would simply to *unset* skipBars whenever show[First|Last]Length is set.  Which I'd be happy to do; afterwards it would just come down to opening a new issue entitled "Enhancement: make showFirstLength compatible with skipBars".  Unless we hear from someone with decent coding abilities soon, I think getting rid of the segfault is the priority here.

     
  • Google Importer

    Google Importer - 2010-10-17

    Originally posted by: percival.music.ca@gmail.com

    The historical fix for segfaults is simply to output an error message ("you can't using showFirstLastLength and skipbars") and then quit cleanly.  I'm fine with unsetting skipBars -- with a warning message -- as well.

    I definitely don't think that "making showFirstLengh work well with skipBars" is a Critical issue.

     
  • Google Importer

    Google Importer - 2010-10-17

    Originally posted by: v.villenave

    OK, then I'll get on it and open a new issue when I'm done.

    Actually, it's a bit more complicated than I thought, since skipBars may be set later in the .ly code (e.g. if for some reason the user sets \compressFullBarRests halfway through their piece).

    I've cleaned the code a bit (which does break Mike's patch, and I apologize for that even though I'm not sure this was the way to go anyway).  I have a couple other ideas on how to deal with this problem, even though some of these may be slightly beyond my reach :-)

    Owner: v.villenave

     
  • Google Importer

    Google Importer - 2010-10-19

    Originally posted by: v.villenave

    The problem is actually much more serious than it looked, and Mike's patch actually doesn't address the underlying cause.

    I'm opening a new issue 1336 to address the underlying cause of the problem. Anyway, it's now officially out of my league.

    Mergedinto: 1336
    Labels: -Patch
    Owner: ---
    Status: Duplicate

     
  • Google Importer

    Google Importer - 2010-10-26

    Originally posted by: v.villenave

    (No comment was entered for this change.)

    Mergedinto: -1336
    Status: Verified

     
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.