Commit 8903ca40 authored by Denis Bilenko's avatar Denis Bilenko

hub.py: use "is" instead of "==" to check greenlets for equality

parent afeab520
......@@ -196,7 +196,7 @@ class Hub(greenlet):
traceback.print_exception(type, value, tb)
del tb
if where is None or issubclass(type, self.SYSTEM_ERROR):
if getcurrent() == self:
if getcurrent() is self:
self.parent.throw(type, value)
else:
self.loop.run_callback(self.parent.throw, type, value)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment