Add a sanity check to partially-correct input

I was generating compressed base64 strings of the form "abc/def". I
accidentally tried decompressing just the "abc" portion of the string,
causing decompress() to hang indefinitely. This index/length check
prevents that case.
Merge pull request #15 from J0eCool/master

Add a sanity check to partially-correct input