Fixed to work with python3.3