cadb863ddfbcc1f97b04f0d0b8ef73db862dd060
tdreszer
  Thu Jul 28 16:32:04 2011 -0700
Fixed some hash sizes, moved some validation code from mdb.c to cv.c, added numeric sort of hgFileUi filerBy and track/file search of terms defined in cv validation as integer.
diff --git src/lib/ra.c src/lib/ra.c
index 69e6e7a..72832d0 100644
--- src/lib/ra.c
+++ src/lib/ra.c
@@ -303,31 +303,31 @@
     if (key == NULL)
         errAbort("Couldn't find key field %s line %d of %s",
 		keyField, lf->lineIx, lf->fileName);
     hashAdd(bigHash, key, hash);
     }
 lineFileClose(&lf);
 return bigHash;
 }
 
 struct hash *raReadWithFilter(char *fileName, char *keyField,char *filterKey,char *filterValue)
 /* Return hash that contains all filtered ra records in file keyed by given field, which must exist.
  * The values of the hash are themselves hashes.  The filter is a key/value pair that must exist.
  * Example raReadWithFilter(file,"term","type","antibody"): returns hash of hashes of every term with type=antibody */
 {
 struct lineFile *lf = lineFileOpen(fileName, TRUE);
-struct hash *bigHash = hashNew(6);
+struct hash *bigHash = hashNew(10);
 struct hash *hash;
 while ((hash = raNextRecord(lf)) != NULL)
     {
     char *key = hashFindVal(hash, keyField);
     if (key == NULL)
         errAbort("Couldn't find key field %s line %d of %s",
                 keyField, lf->lineIx, lf->fileName);
     if (filterKey != NULL)
         {
         char *filter = hashFindVal(hash, filterKey);
         if (filter == NULL)
             {
             hashFree(&hash);
             continue;
             }