tree-wide: when %m is used in log_*, always specify errno explicitly
All those uses were correct, but I think it's better to be explicit. Using implicit errno is too error prone, and with this change we can require (in the sense of a style guideline) that the code is always specified. Helpful query: git grep -n -P 'log_[^s][a-z]+\(.*%m'
This commit is contained in:
@@ -50,7 +50,7 @@ DEFINE_TRIVIAL_CLEANUP_FUNC(context_t, context_free);
|
||||
static int cached_use = -1;
|
||||
static struct selabel_handle *label_hnd = NULL;
|
||||
|
||||
#define log_enforcing(...) log_full(security_getenforce() == 1 ? LOG_ERR : LOG_DEBUG, __VA_ARGS__)
|
||||
#define log_enforcing(...) log_full_errno(security_getenforce() == 1 ? LOG_ERR : LOG_DEBUG, errno, __VA_ARGS__)
|
||||
#endif
|
||||
|
||||
bool mac_selinux_have(void) {
|
||||
|
||||
Reference in New Issue
Block a user