only add socket.sslerror to exception list if needed

git-svn-id: https://linkchecker.svn.sourceforge.net/svnroot/linkchecker/trunk/linkchecker@2156 e7d03fd6-7b0d-0410-9947-9c21f3af8025
This commit is contained in:
calvin 2005-01-18 17:04:31 +00:00
parent 194b1f4466
commit 8ac75ce155

View file

@ -1,5 +1,7 @@
# -*- coding: iso-8859-1 -*-
"""main function module for link checking"""
"""
Main functions for link checking.
"""
# Copyright (C) 2000-2005 Bastian Kleineidam
#
# This program is free software; you can redistribute it and/or modify
@ -58,7 +60,7 @@ ExcList = [
ftplib.error_proto,
]
# XXX remove this when depending on python >= 2.4
if hasattr(socket, "sslerror"):
if hasattr(socket, "sslerror") and sys.version_info >= (2, 4, 0, 'final', 0):
ExcList.append(socket.sslerror)