Fix to work with Python 2.6
Merge pull request #30 from SandyWalsh/python26_fix

Fix to work with Python 2.6