Rizin
unix-like reverse engineering framework and cli tools
|
#include "rz_log.h"
Go to the source code of this file.
Macros | |
#define | RZ_STATIC_ASSERT(x) |
#define | RZ_FUNCTION ((const char *)("???")) |
#define | rz_warn_if_reached() |
#define | rz_warn_if_fail(expr) |
#define | RZ_CHECKS_LEVEL 2 |
#define | H_LOG_(loglevel, fmt, ...) rz_assert_log(loglevel, fmt, __VA_ARGS__) |
#define | rz_return_if_fail(expr) |
#define | rz_return_val_if_fail(expr, val) |
#define | rz_return_if_reached() |
#define | rz_return_val_if_reached(val) |
#define | rz_goto_if_reached(where) |
Functions | |
RZ_API void | rz_assert_log (RzLogLevel level, const char *fmt,...) RZ_PRINTF_CHECK(2 |
#define H_LOG_ | ( | loglevel, | |
fmt, | |||
... | |||
) | rz_assert_log(loglevel, fmt, __VA_ARGS__) |
Definition at line 79 of file rz_assert.h.
#define RZ_CHECKS_LEVEL 2 |
Definition at line 52 of file rz_assert.h.
#define RZ_FUNCTION ((const char *)("???")) |
Definition at line 26 of file rz_assert.h.
#define rz_goto_if_reached | ( | where | ) |
Definition at line 128 of file rz_assert.h.
#define rz_return_if_fail | ( | expr | ) |
rz_return_if_fail: @expr: the expression to check
Verifies that the expression @expr, usually representing a precondition, evaluates to true
. If the function returns a value, use rz_return_val_if_fail() instead.
If @expr evaluates to FALSE, the current function should be considered to have undefined behaviour (a programmer error). The only correct solution to such an error is to change the module that is calling the current function, so that it avoids this incorrect call.
To make this undefined behaviour visible, if @expr evaluates to FALSE, the result is usually that a critical message is logged and the current function returns.
Definition at line 100 of file rz_assert.h.
#define rz_return_if_reached | ( | ) |
Definition at line 116 of file rz_assert.h.
Definition at line 108 of file rz_assert.h.
#define rz_return_val_if_reached | ( | val | ) |
Definition at line 122 of file rz_assert.h.
#define RZ_STATIC_ASSERT | ( | x | ) |
Definition at line 10 of file rz_assert.h.
#define rz_warn_if_fail | ( | expr | ) |
Definition at line 35 of file rz_assert.h.
#define rz_warn_if_reached | ( | ) |
Definition at line 29 of file rz_assert.h.
RZ_API void rz_assert_log | ( | RzLogLevel | level, |
const char * | fmt, | ||
... | |||
) |