Add assert.
authorCarl Hetherington <carl@carlh.net>
Fri, 30 Dec 2011 20:05:40 +0000 (20:05 +0000)
committerCarl Hetherington <carl@carlh.net>
Fri, 30 Dec 2011 20:05:40 +0000 (20:05 +0000)
git-svn-id: svn://localhost/ardour2/branches/3.0@11119 d708f5d6-7413-0410-9779-e7cbd77b26cf

libs/ardour/tempo.cc

index d6e33b6b44834a6ec0718046bcc3ed16fde26ff0..d96c712c16ef515ecb8e84b40d6ec456969a8f38 100644 (file)
@@ -2430,7 +2430,7 @@ Evoral::MusicalTime
 TempoMap::framewalk_to_beats (framepos_t pos, framecnt_t distance) const
 {
        Metrics::const_iterator i;
-       const TempoSection* tempo;
+       const TempoSection* tempo = 0;
        
        /* Find the starting tempo */
 
@@ -2447,6 +2447,8 @@ TempoMap::framewalk_to_beats (framepos_t pos, framecnt_t distance) const
                }
        }
 
+       assert (tempo);
+
        /* We now have:
 
           tempo -> the Tempo for "pos"