mirror of
https://github.com/codex-storage/deluge.git
synced 2025-02-02 14:44:21 +00:00
Catch exceptions while loading the geoip db
This commit is contained in:
parent
7e7944a085
commit
9ed0a80679
@ -87,7 +87,12 @@ class Core(component.Component):
|
||||
# Load the GeoIP DB for country look-ups if available
|
||||
geoip_db = pkg_resources.resource_filename("deluge", os.path.join("data", "GeoIP.dat"))
|
||||
if os.path.exists(geoip_db):
|
||||
self.session.load_country_db(geoip_db)
|
||||
try:
|
||||
self.session.load_country_db(geoip_db)
|
||||
except Exception, e:
|
||||
log.error("Unable to load geoip database!")
|
||||
log.exception(e)
|
||||
|
||||
|
||||
# Set the user agent
|
||||
self.settings = lt.session_settings()
|
||||
|
Loading…
x
Reference in New Issue
Block a user