I don't think the above is needed, just change all the "long" to "int" in the module.

Also all the Ls, as in 12L, 100L, etc. will cause a syntax error in Py 3.3 and are not needed in Py 2.7, so just get rid of them.