Don't attempt to deserialize protobuf from stream if it's too short.

Fixed #198.