In Windows, does “The exception unknown software exception (0x40000015) occurred in the application” mean STATUS_FATAL_APP_EXIT?

前端 未结 1 1556
我在风中等你
我在风中等你 2021-01-05 08:54

At shutdown (initiated by an UPS) my application crashes and a messagebox appears.

The text in the messagebox is \"The exception unknown software exception (0x40000

1条回答
  •  北海茫月
    2021-01-05 09:22

    Yes, 0x40000015 means STATUS_FATAL_APP_EXIT. Your app causes an unhandled runtime exception during shutdown. Some runtime exceptions are actually handled if you don't handle them yourself, and some of these default handlers call abort(). By default, abort calls:

    _call_reportfault(_CRT_DEBUGGER_ABORT, STATUS_FATAL_APP_EXIT, EXCEPTION_NONCONTINUABLE);
    

    abort is a generic termination - it doesn't know what specific exception prompted it to be called, hence the generic 'unknown software exception' message.

    One path to abort is via the _purecall exception - calling an unimplemented pure virtual call.

    Gleaned from purevirt.c and abort.c in the Visual Studio\VC\crt\src directory.


    MSDN has documentation on overriding the default pure call exception handler.

    Here are some related questions:

    • Capturing R6025 pure virtual call
    • Where do "pure virtual function call" crashes come from?
    • Shutdown exception handling for Win32/C++

    0 讨论(0)
提交回复
热议问题