diff options
author | Michael Stahl <mstahl@redhat.com> | 2014-08-22 17:42:42 +0200 |
---|---|---|
committer | Michael Stahl <mstahl@redhat.com> | 2014-08-25 13:21:57 +0200 |
commit | d386f88774df977691f9cb6ab231aa5b085d0b70 (patch) | |
tree | 2e66981b0deab4eddaf3389cd8b7fb6c21004f57 /dtrans/source/win32 | |
parent | b70fb7d704aa721cf7b1f3ce1120f84f89429479 (diff) |
set names on the Win32-only threads
Nice to see what weird threads are running.
Change-Id: Ic9888aa3260d0aeb5858cde5415571ab23c75484
Diffstat (limited to 'dtrans/source/win32')
-rw-r--r-- | dtrans/source/win32/clipb/MtaOleClipb.cxx | 4 | ||||
-rw-r--r-- | dtrans/source/win32/dnd/source.cxx | 3 | ||||
-rw-r--r-- | dtrans/source/win32/dnd/target.cxx | 3 |
3 files changed, 10 insertions, 0 deletions
diff --git a/dtrans/source/win32/clipb/MtaOleClipb.cxx b/dtrans/source/win32/clipb/MtaOleClipb.cxx index 1747eecdaa03..c28d56493791 100644 --- a/dtrans/source/win32/clipb/MtaOleClipb.cxx +++ b/dtrans/source/win32/clipb/MtaOleClipb.cxx @@ -40,6 +40,7 @@ #include "MtaOleClipb.hxx" #include <osl/conditn.hxx> +#include <osl/thread.h> #include <wchar.h> #include <process.h> @@ -740,6 +741,8 @@ unsigned int CMtaOleClipboard::run( ) unsigned int WINAPI CMtaOleClipboard::oleThreadProc( LPVOID pParam ) { + osl_setThreadName("CMtaOleClipboard::run()"); + CMtaOleClipboard* pInst = reinterpret_cast<CMtaOleClipboard*>( pParam ); OSL_ASSERT( NULL != pInst ); @@ -749,6 +752,7 @@ unsigned int WINAPI CMtaOleClipboard::oleThreadProc( LPVOID pParam ) unsigned int WINAPI CMtaOleClipboard::clipboardChangedNotifierThreadProc( LPVOID pParam ) { + osl_setThreadName("CMtaOleClipboard::clipboardChangedNotifierThreadProc()"); CMtaOleClipboard* pInst = reinterpret_cast< CMtaOleClipboard* >( pParam ); OSL_ASSERT( NULL != pInst ); diff --git a/dtrans/source/win32/dnd/source.cxx b/dtrans/source/win32/dnd/source.cxx index aed131fe94f7..d7907f59c8aa 100644 --- a/dtrans/source/win32/dnd/source.cxx +++ b/dtrans/source/win32/dnd/source.cxx @@ -30,6 +30,7 @@ #include "sourcecontext.hxx" #include "../../inc/DtObjFactory.hxx" #include <rtl/ustring.h> +#include <osl/thread.h> #include <winuser.h> #include <stdio.h> @@ -310,6 +311,8 @@ Sequence< OUString > SAL_CALL DragSource::getSupportedServiceNames( ) throw (Ru XSourceListener. */ unsigned __stdcall DndOleSTAFunc(LPVOID pParams) { + osl_setThreadName("DragSource DndOleSTAFunc"); + // The structure contains all arguments for DoDragDrop and other DragSource *pSource= (DragSource*)pParams; diff --git a/dtrans/source/win32/dnd/target.cxx b/dtrans/source/win32/dnd/target.cxx index 6a6afe898e43..f7f770444ab9 100644 --- a/dtrans/source/win32/dnd/target.cxx +++ b/dtrans/source/win32/dnd/target.cxx @@ -27,6 +27,7 @@ #include "targetdropcontext.hxx" #include "targetdragcontext.hxx" #include <rtl/ustring.h> +#include <osl/thread.h> using namespace cppu; using namespace osl; @@ -185,6 +186,8 @@ void SAL_CALL DropTarget::initialize( const Sequence< Any >& aArguments ) // DoDragDrop. The thread also notifies all XSourceListener. DWORD WINAPI DndTargetOleSTAFunc(LPVOID pParams) { + osl_setThreadName("DropTarget DndTargetOleSTAFunc"); + HRESULT hr= OleInitialize( NULL); if( SUCCEEDED( hr) ) { |