92e11163659de6cc7ec35fc41d299f29ff8c9952 hiram Mon Jan 7 23:37:29 2019 -0800 fixup warnings from gcc-7 compiler refs #22738 diff --git src/hg/nci60/findStanAlignments.c src/hg/nci60/findStanAlignments.c index 5d1b683..5ed6b29 100644 --- src/hg/nci60/findStanAlignments.c +++ src/hg/nci60/findStanAlignments.c @@ -133,33 +133,35 @@ sprintf(buff, "%d", sm->clid); printf("Looking for %s\n", buff); ic = hashFindVal(iHash, buff); if(ic != NULL) { /* first try looking for the image clones themselves... */ for(i=0; inumGenbank; i++) { char query[1024]; sqlSafef(query, sizeof query, "select * from all_est where qName='%s'", ic->genbankIds[i]); pslList = pslLoadByQuery(conn, buff); if(pslList != NULL) { slSort(&pslList, pslCmpScore); if(bestPsl == NULL || (pslScore(pslList) > pslScore(bestPsl))) + { pslFree(&bestPsl); bestPsl = copyPsl(pslList); } + } pslFreeList(&pslList); } if(bestPsl != NULL) { freez(&bestPsl->qName); sprintf(buff, "%d", sm->clid); bestPsl->qName = cloneString(buff); pslTabOut(bestPsl,out); } else { fprintf(out, "%d\talignment unknown\n", sm->clid); }