Ignore:
Timestamp:
Dec 15, 2008, 11:05:34 PM (16 years ago)
Author:
[email protected]
Message:

Reviewed by Darin Adler.

<rdar://problem/6445089> Mach ports leak from worker threads

  • interpreter/Interpreter.cpp: (JSC::getCPUTime): Deallocate the thread self port.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/interpreter/Interpreter.cpp

    r39265 r39329  
    11381138
    11391139    // Get thread information
    1140     thread_info(mach_thread_self(), THREAD_BASIC_INFO, reinterpret_cast<thread_info_t>(&info), &infoCount);
     1140    mach_port_t threadPort = mach_thread_self();
     1141    thread_info(threadPort, THREAD_BASIC_INFO, reinterpret_cast<thread_info_t>(&info), &infoCount);
     1142    mach_port_deallocate(mach_task_self(), threadPort);
    11411143   
    11421144    unsigned time = info.user_time.seconds * 1000 + info.user_time.microseconds / 1000;
Note: See TracChangeset for help on using the changeset viewer.