attractivechaos / klib

A standalone and lightweight C library
http://attractivechaos.github.io/klib/
MIT License
4.18k stars 556 forks source link

Fix a trivial error check in kseq. #169

Open jkbonfield opened 1 year ago

jkbonfield commented 1 year ago

In porting #78 over to htslib, I found a bug due to bracketing.

In the original code, c is set to the result of the whole boolean if statement, so 0 or 1. Thus the if (c == -3) check can never pass.