Changeset 37040 in webkit for trunk/JavaScriptCore/wtf


Ignore:
Timestamp:
Sep 28, 2008, 11:56:50 AM (17 years ago)
Author:
Simon Hausmann
Message:

2008-09-28 Simon Hausmann <Simon Hausmann>

Reviewed by David Hyatt.

In Qt's initializeThreading re-use an existing thread identifier for the main
thread if it exists.

currentThread() implicitly creates new identifiers and it could be that
it is called before initializeThreading().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/wtf/ThreadingQt.cpp

    r36763 r37040  
    128128        wtf_random_init();
    129129        QThread* mainThread = QCoreApplication::instance()->thread();
    130         mainThreadIdentifier = establishIdentifierForThread(mainThread);
     130        mainThreadIdentifier = identifierByQthreadHandle(mainThread);
     131        if (!mainThreadIdentifier)
     132            mainThreadIdentifier = establishIdentifierForThread(mainThread);
    131133        initializeMainThread();
    132134    }
Note: See TracChangeset for help on using the changeset viewer.