Skip to content

Commit bc70c51

Browse files
committed
Fixed bug affecting multi-record GFFs and GTFs
1 parent 2842353 commit bc70c51

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/GFF/reader.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ function parsechromosome!(input, record::Record{G}) where G <: AbstractGene
8383
record.name = seqid
8484
elseif seqid != record.name
8585
### The following contig lacks a header
86-
TranscodingStreams.unread(input, UInt8.(c for c in line))
86+
TranscodingStreams.unread(input, UInt8.(c for c in "$line\n"))
8787
return record
8888
end
8989
loc = if strand == "+"
@@ -132,7 +132,7 @@ function parsechromosome!(input, record::Record{G}) where G <: AbstractGene
132132
if !isempty(currentfasta)
133133
record.sequence = LongDNA{4}(String(take!(iobuffer)))
134134
end
135-
record.header = headerstring = String(take!(header))
135+
record.header = String(take!(header))
136136
if isempty(record.name)
137137
return nothing
138138
else

src/GTF/reader.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ function parsechromosome!(input, record::Record{G}) where G <: AbstractGene
8080
record.name = seqid
8181
elseif seqid != record.name
8282
### The following contig lacks a header
83-
TranscodingStreams.unread(input, UInt8.(c for c in line))
83+
TranscodingStreams.unread(input, UInt8.(c for c in "$line\n"))
8484
return record
8585
end
8686
loc = if strand == "+"

0 commit comments

Comments
 (0)