4940e907275b34957f5182ca6daa7ac8a2679803 braney Mon Feb 22 15:44:04 2021 -0800 check for a NULL cart diff --git src/hg/lib/hgFind.c src/hg/lib/hgFind.c index 4b81034..ece5d10 100644 --- src/hg/lib/hgFind.c +++ src/hg/lib/hgFind.c @@ -2882,31 +2882,31 @@ struct hgFindSpec *shortList = NULL, *longList = NULL; struct hgFindSpec *hfs; boolean done = FALSE; // Disable singleBaseSpec for any term that is not hgOfficialChromName // because that mangles legitimate IDs that are [A-Z]:[0-9]+. if (singleBaseSpec) { singleBaseSpec = relativeFlag = FALSE; term = cloneString(originalTerm); // restore original term relStart = relEnd = 0; } if (!trackHubDatabase(db)) hgFindSpecGetAllSpecs(db, &shortList, &longList); - if (cartOptionalString(cart, "noShort") == NULL) + if ((cart == NULL) || (cartOptionalString(cart, "noShort") == NULL)) { hgp->shortCircuited = TRUE; for (hfs = shortList; hfs != NULL; hfs = hfs->next) { if (hgFindUsingSpec(cart, db, hfs, term, limitResults, hgp, relativeFlag, relStart, relEnd, multiTerm)) { done = TRUE; if (! hgFindSpecSetting(hfs, "semiShortCircuit")) break; } } } else cartRemove(cart, "noShort");