diff options
author | Martin Smith <msmith@trolltech.com> | 2010-04-09 13:16:09 (GMT) |
---|---|---|
committer | Martin Smith <msmith@trolltech.com> | 2010-04-09 13:16:09 (GMT) |
commit | 0bd75b67bc23d51670822305a31e19a74ca7134e (patch) | |
tree | 41b37d4e21ffd4b7bb7974e6b2bf9aa6494b5781 /src/corelib/thread/qthread_unix.cpp | |
parent | 5e5836702662783a4fba5f95a487948e5c6d2a4e (diff) | |
parent | e4cae397e3737551752487000e152162d0878f88 (diff) | |
download | Qt-0bd75b67bc23d51670822305a31e19a74ca7134e.zip Qt-0bd75b67bc23d51670822305a31e19a74ca7134e.tar.gz Qt-0bd75b67bc23d51670822305a31e19a74ca7134e.tar.bz2 |
Merge branch '4.7' of git@scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.7
Diffstat (limited to 'src/corelib/thread/qthread_unix.cpp')
-rw-r--r-- | src/corelib/thread/qthread_unix.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/corelib/thread/qthread_unix.cpp b/src/corelib/thread/qthread_unix.cpp index 5a50646..6b34b5f 100644 --- a/src/corelib/thread/qthread_unix.cpp +++ b/src/corelib/thread/qthread_unix.cpp @@ -136,6 +136,12 @@ static void create_current_thread_data_key() pthread_key_create(¤t_thread_data_key, destroy_current_thread_data); } +static void destroy_current_thread_data_key() +{ + pthread_key_delete(current_thread_data_key); +} +Q_DESTRUCTOR_FUNCTION(destroy_current_thread_data_key) + QThreadData *QThreadData::current() { pthread_once(¤t_thread_data_once, create_current_thread_data_key); |