From 19c2ce7fe08bc8fa0506f69cdcfe819cc90b46ed Mon Sep 17 00:00:00 2001 From: calvin Date: Sun, 24 Sep 2006 10:05:10 +0000 Subject: [PATCH] catch thread errors separately git-svn-id: https://linkchecker.svn.sourceforge.net/svnroot/linkchecker/trunk/linkchecker@3481 e7d03fd6-7b0d-0410-9947-9c21f3af8025 --- linkcheck/director/__init__.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/linkcheck/director/__init__.py b/linkcheck/director/__init__.py index 62fecb87..fea647c9 100644 --- a/linkcheck/director/__init__.py +++ b/linkcheck/director/__init__.py @@ -18,6 +18,7 @@ Management of checking a queue of links with several threads. """ import time +import thread import linkcheck import linkcheck.log import linkcheck.cache.urlqueue @@ -43,6 +44,11 @@ def check_urls (aggregate): aggregate.logger.end_log_output() except KeyboardInterrupt: interrupt(aggregate) + except thread.error: + linkcheck.log.warn(linkcheck.LOG_CHECK, + _("Could not start a new thread. Check that the current user" \ + " is allowed to start new threads.")) + abort(aggregate) except: console.internal_error() abort(aggregate)