Reverted some overzealous 3to2 changes (exception syntax, class decorators).
use_integer_ipv4 forgot to use 'global' to redefine the outer-scope data.