Fixes #65 with python 2/3 compatibility

Solves the:
TypeError: 'str' does not support the buffer interface
referenced in #65

Tested with python 3.3.1