| Previous | Next |
| STATUS_LICENSE_VIOLATION | STATUS_DRIVER_UNABLE_TO_LOAD |
STATUS_DLL_INIT_FAILED_LOGOFF
The loader encountered DLL initialization while the session was closing
Process and DLL initialization can race with user logoff and window-station teardown. This status indicates that initialization requiring the interactive session could not proceed because that environment was shutting down. It is distinct from a generic DllMain failure caused by missing imports or application configuration.
Retry loops inside the terminating session are usually ineffective. Services and background agents should avoid depending on interactive desktops, while applications should stop creating new helper processes and loading optional UI modules after receiving shutdown or session-end notifications.
What to inspect
- Correlate the timestamp with logoff, session-change, process creation, and service-control events.
- Identify which DLL initialization path touches USER, GDI, COM apartments, profiles, or window-station objects.
- Ensure shutdown handlers stop worker creation and complete outstanding initialization before session teardown.
- Move nonessential work out of DllMain and design services to operate without the interactive window station.
References
- Microsoft Open Specifications: NTSTATUS values
- Microsoft: DllMain entry point
- Microsoft: LoadLibrary
- Microsoft: run-time dynamic linking
Looking for a different code? Search another status or error code.
