| Previous | Next |
| RPC_E_WRONG_THREAD | RPC_E_VERSION_MISMATCH |
RPC_E_THREAD_NOT_INIT
Current thread has not initialized COM
RPC_E_THREAD_NOT_INIT is HRESULT 2147549455 (0x8001010F) from winerror.h. The documented description is “CoInitialize has not been called on the current thread.” The relevant context is the COM/RPC call control, message filtering, apartment routing, marshaling, security negotiation, or remote object lifetime.
Where it is encountered
- Cross-apartment or cross-process COM method invocation and activation.
- STA message filtering, reentrancy, call cancellation, timeout, or retry handling.
- DCOM security initialization, proxy/stub marshaling, OBJREF processing, and server object lifetime.
The immediate focus is a thread calling COM or OLE functionality before CoInitialize or CoInitializeEx.
What to verify
Verify that the failing thread and its intended apartment model are identified, including framework threads created outside application startup.
Correct handling and recovery
Initialize COM on that thread before COM calls and balance every successful initialization with CoUninitialize. Choose STA or MTA deliberately.
Reconcile partial output and server-side effects before attempting the operation again.
Practical scenario
A thread-pool callback creates a COM parser without initializing COM. A scoped initializer configures the worker as MTA and balances cleanup.
Difference from nearby HRESULTs
It means COM was never initialized on the thread; RPC_E_WRONG_THREAD means COM exists but the interface belongs elsewhere.
References
Looking for a different code? Search another status or error code.