18d303bb4f14e1edff401c8a85276ff1344f0f37 angie Tue Apr 3 10:18:14 2012 -0700 Feature #6152 (Variant Annotation Tool): Added annoStreamVcf, whichled to yet more significant changes to annoRow: instead of every row declaring its type and annoRow{Free,Clone} taking a numCols argument that is meaningless for wig, now annoRow{Free,Clone} take the row's source annoStreamer as an argument. The annoStreamer now has public members (rowType and numCols) that provide all information needed about the row. annoStreamer constructors need to set rowType. diff --git src/hg/lib/annoGrateWig.c src/hg/lib/annoGrateWig.c index f7766d7..b43840f 100644 --- src/hg/lib/annoGrateWig.c +++ src/hg/lib/annoGrateWig.c @@ -52,27 +52,27 @@ } } } static struct annoRow *agwdIntegrate(struct annoGrator *self, struct annoRow *primaryRow, boolean *retRJFilterFailed) /* Return wig annoRows that overlap primaryRow position, with NANs weeded out. */ { struct annoRow *rowsIn = annoGratorIntegrate(self, primaryRow, retRJFilterFailed); if (retRJFilterFailed && *retRJFilterFailed) return NULL; struct annoRow *rowIn, *rowOutList = NULL;; for (rowIn = rowsIn; rowIn != NULL; rowIn = rowIn->next) tidyUp(rowIn, &rowOutList, primaryRow->start, primaryRow->end); slReverse(&rowOutList); -annoRowFreeList(&rowsIn, -1); +annoRowFreeList(&rowsIn, self->mySource); return rowOutList; } struct annoGrator *annoGrateWigDbNew(char *db, char *table, int maxOutput) /* Create an annoGrator subclass for wiggle data from db.table (and the file it points to). */ { struct annoStreamer *wigSource = annoStreamWigDbNew(db, table, maxOutput); struct annoGrator *self = annoGratorNew(wigSource); self->integrate = agwdIntegrate; return self; }