mbedtls_error_add() function
Combines a high-level and low-level error code together. This function can be called directly however it is usually called via the #MBEDTLS_ERROR_ADD macro. While a value of zero is not a negative error code, it is still an error code (that denotes success) and can be combined with both a negative error code or another value of zero.
Syntax
static inline int mbedtls_error_add(int high,
int low,
const char *file,
int line);
Arguments
high
high-level error code. See error.h for more details.
low
low-level error code. See error.h for more details.
file
file where this error code addition occurred.
line
line where this error code addition occurred.
Notes
When invasive testing is enabled via #MBEDTLS_TEST_HOOKS, also try to call \link mbedtls_test_hook_error_add \endlink.