11c1c560b88d430fd2c6967a86d2e87109806357
max
  Fri Jan 24 09:15:03 2014 -0800
corrections after code review refs #12524. These changes probably don'tneed to reviewed anymore, as Angie has already seen them, I copied them into
the ticket #12524.

diff --git src/hg/lib/hgFind.c src/hg/lib/hgFind.c
index f2d2f0a..33f300e 100644
--- src/hg/lib/hgFind.c
+++ src/hg/lib/hgFind.c
@@ -539,51 +539,49 @@
 struct hgPosTable *table;
 AllocVar(table);
 if (hTableExists(db, "kgProtMap2"))
     table->description = cloneString("UCSC Genes");
 else
     table->description = cloneString("Known Genes");
 table->name = cloneString("knownGene");
 slAddHead(&hgp->tableList, table);
 return table;
 }
 
 char *makeIndexPath(char *db)
 {
 /* create the pathname with the knowngene index for a db, result needs to be freed */
 char *path = needMem(PATH_LEN);
-char *gbdbLoc = cfgOptionDefault("gbdb.loc", "/gbdb/");
-safef(path, PATH_LEN, "%s%s/knownGene.ix", gbdbLoc, db);
-return path;
+safef(path, PATH_LEN, "/gbdb/%s/knownGene.ix", db);
+char *newPath = hReplaceGbdb(path);
+freez(&path);
+return newPath;
 }
 
 static boolean gotFullText(char *db)
 /* Return TRUE if we have full text index. */
 {
 char *indexPath = makeIndexPath(db);
 boolean result = FALSE;
 
-if (udcIsLocal(indexPath))
-    if (fileExists(indexPath))
+if (udcExists(indexPath))
     result = TRUE;
 else
     {
     warn("%s doesn't exist", indexPath);
     result = FALSE;
     }
-else
-    result = TRUE;
 
 freez(&indexPath);
 return result;
 }
 
 struct tsrPos
 /* Little helper structure tying together search result
  * and pos, used by addKnownGeneItems */
     {
     struct tsrPos *next;	/* Next in list. */
     struct trixSearchResult *tsr;	/* Basically a gene symbol */
     struct hgPos *posList;		/* Associated list of positions. */
     };
 
 static void addKnownGeneItems(struct hgPosTable *table,