From 2b01af3de97576dc2d6e5a4897f1fc0488e67879 Mon Sep 17 00:00:00 2001 From: Zdenek Kabelac Date: Wed, 18 Oct 2023 02:19:15 +0200 Subject: [PATCH] filters: fix condition During revork in commit cf46f4baeeaba5f79982e651c1c36c15476f7329 condition was inverted, the check for non-null string is needed. --- lib/filters/filter-sysfs.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/filters/filter-sysfs.c b/lib/filters/filter-sysfs.c index 806363201..762733206 100644 --- a/lib/filters/filter-sysfs.c +++ b/lib/filters/filter-sysfs.c @@ -75,7 +75,7 @@ struct dev_filter *sysfs_filter_create(const char *sysfs_dir) struct dev_filter *f; size_t len; - if (!sysfs_dir || *sysfs_dir) { + if (!sysfs_dir || !*sysfs_dir) { log_verbose("No proc filesystem found: skipping sysfs filter"); return NULL; }