Scroll to navigation

() PMDK Programmer's Manual ()

NAME

pmemobj_log_get_threshold - get the logging threshold value

SYNOPSIS


#include <libpmemobj.h>
int pmemobj_log_get_threshold(enum pmemobj_log_threshold threshold,
enum pmemobj_log_level *value);

DESCRIPTION

pmemobj_log_get_threshold() gets the current value of the threshold. See pmemobj_log_set_threshold(3) for available thresholds and values.

RETURN VALUE

On success, pmemobj_log_get_threshold() function returns 0 and writes into value the current value of the threshold. On failure, it returns a non-zero value and sets errno. In case of failure, the value contents is undefined.

ERRORS

pmemobj_log_get_threshold() can fail with the following errors:

EINVAL - threshold is not PMEMOBJ_LOG_THRESHOLD nor PMEMOBJ_LOG_THRESHOLD_AUX
EINVAL - value is NULL

SEE ALSO

pmemobj_log_set_function(3), pmemobj_log_set_threshold(3).

2024-05-23 PMDK -