Python 2.6 compatibility

There are minimal changes required to support Python 2.6, which I and many others are unfortunately stuck with for the time being. The c compiles perfectly well and all the tests pass. I don't know whether or not you're interested in supporting 2.6 long term but, again, the required changes at the moment are minimal :)

Also, thank you for the great lib!