src/hg/hgTracks/mafTrack.c 1.64

1.64 2009/05/14 21:45:24 braney
check for zero size before calling maf score function
Index: src/hg/hgTracks/mafTrack.c
===================================================================
RCS file: /projects/compbio/cvsroot/kent/src/hg/hgTracks/mafTrack.c,v
retrieving revision 1.63
retrieving revision 1.64
diff -b -B -U 4 -r1.63 -r1.64
--- src/hg/hgTracks/mafTrack.c	28 Oct 2008 13:44:38 -0000	1.63
+++ src/hg/hgTracks/mafTrack.c	14 May 2009 21:45:24 -0000	1.64
@@ -462,8 +462,10 @@
 
         /* Take the score over the relevant range of text symbols in the maf,
          * and divide it by the bases we cover in the master genome to 
          * get a normalized by base score. */ 
+	score = 0;
+	if (deltaT != 0)
 	score = mafScoreRangeMultiz(maf, t1, deltaT)/(b2-b1);
 
         /* Scale the score so that it is between 0 and 1 */ 
 	score = (score - minScore) * scoreScale;