Thank Heng for that one. I had a comment on this line saying "most disgusting line of code I've ever written" but then I thought that there is probably something more disgusting out there, so I took out the comment.

I thought about that, but don't you think we should keep all our char * manipulation with htslib related stuff? If we put in utils, we'll be sort of encouraging it.