Skip to content

Commit 0ee1b3b

Browse files
committed
fix a regression bug of FASTQ reader
#491
1 parent ca559a7 commit 0ee1b3b

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

src/fastqreader.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -307,10 +307,11 @@ Read* FastqReader::read(){
307307

308308
getLine(name);
309309
// name should start with @
310-
if (name->empty() || (*name)[0]!='@') {
311-
cerr << *name << endl;
312-
error_exit("Read name line should start with '@'");
310+
while((name->empty() && !(mBufUsedLen >= mBufDataLen && bufferFinished())) || (!name->empty() && (*name)[0]!='@')){
311+
getLine(name);
313312
}
313+
if(name->empty())
314+
return NULL;
314315

315316
getLine(sequence);
316317
getLine(strand);

0 commit comments

Comments
 (0)