Fix server.py to work with Python < 2.6