diff options
author | aleherbau | 2011-05-12 09:05:20 +0000 |
---|---|---|
committer | aleherbau | 2011-05-12 09:05:20 +0000 |
commit | fa85be44ccd955603e514bc2ed7a107e1f56f8f1 (patch) | |
tree | bc3b39b96184c89d4ef1f744107c673671bea7b3 /python/src/tcf/EventQueue.py | |
parent | cd93aae3bec36af01c72b4433c8a4c647560a8de (diff) | |
download | org.eclipse.tcf-fa85be44ccd955603e514bc2ed7a107e1f56f8f1.tar.gz org.eclipse.tcf-fa85be44ccd955603e514bc2ed7a107e1f56f8f1.tar.xz org.eclipse.tcf-fa85be44ccd955603e514bc2ed7a107e1f56f8f1.zip |
TCF Python: Fixed frequent 10054 error messages on windows, code cleanup
Diffstat (limited to 'python/src/tcf/EventQueue.py')
-rw-r--r-- | python/src/tcf/EventQueue.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/python/src/tcf/EventQueue.py b/python/src/tcf/EventQueue.py index 1c8a3e90c..546991b8f 100644 --- a/python/src/tcf/EventQueue.py +++ b/python/src/tcf/EventQueue.py @@ -9,7 +9,7 @@ # * Wind River Systems - initial API and implementation
# *******************************************************************************
-import threading, exceptions
+import threading
import protocol
class EventQueue(object):
@@ -33,7 +33,7 @@ class EventQueue(object): self.__is_waiting = False
self.__lock.notifyAll()
self.__thread.join()
- except exceptions.Exception as e:
+ except BaseException as e:
protocol.log("Failed to shutdown TCF event dispatch thread", e)
def isShutdown(self):
@@ -53,13 +53,13 @@ class EventQueue(object): self.__lock.wait()
r, args, kwargs = self.__queue.pop(0)
r(*args, **kwargs)
- except exceptions.Exception as x:
+ except BaseException as x:
self.__error(x)
def invokeLater(self, r, *args, **kwargs):
- assert r;
+ assert r
with self.__lock:
- if self.__is_shutdown: raise exceptions.RuntimeError("TCF event dispatcher has shut down")
+ if self.__is_shutdown: raise RuntimeError("TCF event dispatcher has shut down")
self.__queue.append((r, args, kwargs))
if self.__is_waiting:
self.__is_waiting = False
|