diff options
| author | Bjoern A. Zeeb <bz@FreeBSD.org> | 2025-05-04 19:52:11 +0000 |
|---|---|---|
| committer | Bjoern A. Zeeb <bz@FreeBSD.org> | 2025-05-07 08:52:14 +0000 |
| commit | 033e97bababed3fc6b4f183d8a0969598fa52d05 (patch) | |
| tree | 2cc0b1c6456197d800f72338cc0c44a1e47b2897 | |
| parent | 6a0dbc0a1246c9825f0892bb6dd957f5d081057a (diff) | |
LinuxKPI: style
Check results of non-bool to be != 0.
No functional changes intended.
Sponsored by: The FreeBSD Foundation
Reviewed by: emaste
Differential Revision: https://reviews.freebsd.org/D50158
(cherry picked from commit 76b66ac45ea804f23ffb35712b0ceaa98864c06f)
| -rw-r--r-- | sys/compat/linuxkpi/common/src/linux_kobject.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/compat/linuxkpi/common/src/linux_kobject.c b/sys/compat/linuxkpi/common/src/linux_kobject.c index ddd0a58660f1..8e71b5d69073 100644 --- a/sys/compat/linuxkpi/common/src/linux_kobject.c +++ b/sys/compat/linuxkpi/common/src/linux_kobject.c @@ -114,10 +114,10 @@ kobject_add_complete(struct kobject *kobj, struct kobject *parent) for (attr = t->default_attrs; *attr != NULL; attr++) { error = sysfs_create_file(kobj, *attr); - if (error) + if (error != 0) break; } - if (error) + if (error != 0) sysfs_remove_dir(kobj); } return (error); |
