0b79c15eb1f296cb7bb64ab6e7e1d3adf0eb0599
markd
  Wed Sep 20 12:56:24 2023 -0700
fixed unsiged underflow

diff --git src/lib/pslTransMap.c src/lib/pslTransMap.c
index 4efb5b2..50cce93 100644
--- src/lib/pslTransMap.c
+++ src/lib/pslTransMap.c
@@ -113,53 +113,53 @@
 
 static void removeBlock(struct psl *psl, int jBlk)
 /* remove the specified block */
 {
 arrayDelete(psl->blockSizes, jBlk, psl->blockCount);
 arrayDelete(psl->qStarts, jBlk, psl->blockCount);
 arrayDelete(psl->tStarts, jBlk, psl->blockCount);
 psl->blockCount--;
 }
     
 static void editBlockOverlap(struct psl *psl, int iBlk,
                              unsigned overlapAmt3)
 /* remove overlap between two blocks.  If multiple blocks are covered,
  * then shift remove the block */
 {
-while ((overlapAmt3 > 0) && (iBlk < psl->blockCount - 1))
+while ((overlapAmt3 > 0) && (iBlk < ((int)psl->blockCount) - 1))
     {
     int jBlk = iBlk + 1;
     if (overlapAmt3 < psl->blockSizes[jBlk])
         {
         trimBlockOverlap(psl, jBlk, overlapAmt3);
         overlapAmt3 = 0;
         }
     else
         {
         overlapAmt3 -= psl->blockSizes[jBlk];
         removeBlock(psl, jBlk);
         }
     }
 }
 
 static void removeOverlappingBlock(struct psl *psl)
 /* Remove overlapping blocks, which BLAT can create with protein to NA
  * alignments.  These are exposed when convert prot-NA alignments to NA-NA
  * alignment.
  */
 {
-for (int iBlk = 0; iBlk < psl->blockCount - 1; iBlk++)
+for (int iBlk = 0; iBlk < ((int)psl->blockCount) - 1; iBlk++)
     {
     unsigned overlapAmt3 = blockOverlapAmt3(psl, iBlk);
     if (overlapAmt3 > 0)
         editBlockOverlap(psl, iBlk, overlapAmt3);
     }
 setPslBoundsCounts(psl);
 }
 
 
 struct block
 /* Coordinates of a block, which might be aligned or a gap on one side */
 {
     int qStart;          /* Query start position. */
     int qEnd;            /* Query end position. */
     int tStart;          /* Target start position. */