#include "common.h"
#include "mem.h"
#include "filesys.h"
+#include "seq.h"
#include "fasta.h"
// #define OLIGO_SIZE 15
uint C_rc = ( 1 << ( UINT_BITS - 2 ) ); /* 01 on the leftmost two bits an uint. */
seq_entry *entry = NULL;
FILE *fp = NULL;
- file_buffer *buffer = NULL;
array = mem_get_zero( sizeof( uint ) * SIZE );
fp = read_open( path );
- while ( ( fasta_get_entry( &buffer, &entry ) ) )
+ while ( ( fasta_get_entry( fp, &entry ) ) )
{
fprintf( stderr, "Counting oligos in: %s ... ", entry->seq_name );
close_stream( fp );
- fasta_free_entry( entry );
+ free( entry->seq_name );
+ free( entry->seq );
+ entry = NULL;
return array;
}