Skip to content
Snippets Groups Projects
Commit c2cd3bbacef2 authored by Aarni Koskela's avatar Aarni Koskela
Browse files

Try Py2.5 compatibility as last fallback for thread identity.

parent d65eff6d0e3a
No related branches found
No related tags found
No related merge requests found
......@@ -40,5 +40,9 @@
def get_thread_ident():
try: # thread.get_ident() exists from Py2.5 to Py2.7.
# thread.get_ident() exists from Py2.5 to Py2.7.
# threading.current_thread().ident exists from Py2.6 up to Py3.4.
try:
return threading.current_thread().ident
except AttributeError:
return thread.get_ident()
......@@ -44,6 +48,4 @@
return thread.get_ident()
except AttributeError: # threading.current_thread().ident exists from Py2.6 up to Py3.4.
return threading.current_thread().ident
def _get_pageant_window_object():
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment