Avoid reading incomplete utf8 sequences

Fixes issue #9