From: amwaterhouse Date: Wed, 25 Oct 2006 14:57:37 +0000 (+0000) Subject: Return if negative width, ie alignment deleted X-Git-Tag: Release_2_2~230 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=f48c76a5fec4cbe253351bcdebaca4bcb09d98a5;p=jalview.git Return if negative width, ie alignment deleted --- diff --git a/src/jalview/gui/AlignViewport.java b/src/jalview/gui/AlignViewport.java index fb3d4df..f9f32e4 100755 --- a/src/jalview/gui/AlignViewport.java +++ b/src/jalview/gui/AlignViewport.java @@ -280,6 +280,8 @@ public class AlignViewport try { int alWidth = alignment.getWidth(); + if(alWidth<0) + return; Conservation cons = new jalview.analysis.Conservation("All", jalview.schemes.ResidueProperties.propHash, 3, @@ -459,6 +461,8 @@ public class AlignViewport try { int aWidth = alignment.getWidth(); + if(aWidth<0) + return; consensus.annotations = null; consensus.annotations = new Annotation[aWidth];