connection.py: Catches Exception instead of naked.

Closes chfoo/wpull#83.