Add support for old binary type (\x02).

Here is a change with added test too.