a18667f760788b11c048f407bbeb7aaf7b4306e4 braney Fri Nov 14 08:45:08 2025 -0800 fix a problem with highlight item when displaying a bigBed 3 refs #36673 diff --git src/hg/hgTracks/simpleTracks.c src/hg/hgTracks/simpleTracks.c index 79dd8ef74af..20da42a1f17 100644 --- src/hg/hgTracks/simpleTracks.c +++ src/hg/hgTracks/simpleTracks.c @@ -4465,32 +4465,32 @@ if (sameWord(tg->table, "knownGene")) { mapName = cloneString(mapName); chp = strstr(mapName, "&hgg_prot"); if (chp != NULL) *chp = '\0'; } #ifndef GBROWSE /* special case for PCR Results (may have acc+name mapItemName): */ else if (sameString(tg->table, PCR_RESULT_TRACK_NAME)) mapName = pcrResultItemAccession(mapName); #endif /* GBROWSE */ /* Only highlight if names are in the hgFindMatches hash with a 1. */ highlight = (hgFindMatches != NULL && - ( hashIntValDefault(hgFindMatches, name, 0) == 1 || - hashIntValDefault(hgFindMatches, mapName, 0) == 1)); + ( ((name != NULL) && (hashIntValDefault(hgFindMatches, name, 0) == 1)) || + ((mapName != NULL) && hashIntValDefault(hgFindMatches, mapName, 0) == 1))); return highlight; } double scaleForWindow(double width, int seqStart, int seqEnd) /* Return the scale for the window. */ { return width / (seqEnd - seqStart); } boolean nextItemCompatible(struct track *tg) /* Check to see if we draw nextPrev item buttons on a track. */ { return (withNextExonArrows && tg->nextExonButtonable && tg->nextPrevExon); }