Skip to content

SysAbort

SysAbort

Description

Custom abort function that can be redirected for testing purposes. By default, this calls the standard abort() function. If a callback is set via SysSetAbortCallback, it calls the callback instead.

Success

Function does not return (either aborts or calls callback).

Failure

Function cannot fail.

Usage example (Cross-references)

Usage examples (Cross-references)
    }
    
    void SysAbort(void) {
        if (g_abort_callback) {
            g_abort_callback();
    
    // Forward declaration to avoid circular includes
    void SysAbort(void);
    
    ///
            LogWrite(LOG_MESSAGE_TYPE_FATAL, __func__, __LINE__, m_.data);                                                 \
            StrDeinit(&m_);                                                                                                \
            SysAbort();                                                                                                    \
        } while (0)
            LogWrite(LOG_MESSAGE_TYPE_FATAL, __func__, __LINE__, m_.data);                                                 \
            StrDeinit(&m_);                                                                                                \
            SysAbort();                                                                                                    \
        } while (0)
Last updated on