Fix for python3 following gh-1550
Merge pull request #1555 from lamblin/fix_stringio_py3k

Fix for python3 following gh-1550