Avoid excessive decoding

Fixes #11.