git: 3a3af6b2a160 - main - mac_ddb: Fix the show rman validator.
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Fri, 12 Aug 2022 17:21:05 UTC
The branch main has been updated by jhb:
URL: https://cgit.FreeBSD.org/src/commit/?id=3a3af6b2a160bea72509a9d5ef84e25906b0478a
commit 3a3af6b2a160bea72509a9d5ef84e25906b0478a
Author: John Baldwin <jhb@FreeBSD.org>
AuthorDate: 2022-08-12 17:20:05 +0000
Commit: John Baldwin <jhb@FreeBSD.org>
CommitDate: 2022-08-12 17:20:05 +0000
mac_ddb: Fix the show rman validator.
The validator always returned true due to an incorrect check.
Reviewed by: mhorne, imp
Sponsored by: DARPA
Differential Revision: https://reviews.freebsd.org/D36125
---
sys/security/mac_ddb/mac_ddb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sys/security/mac_ddb/mac_ddb.c b/sys/security/mac_ddb/mac_ddb.c
index 847be4997226..84a56e1d276a 100644
--- a/sys/security/mac_ddb/mac_ddb.c
+++ b/sys/security/mac_ddb/mac_ddb.c
@@ -185,7 +185,7 @@ db_show_rman_valid(db_expr_t addr, bool have_addr, db_expr_t count, char *modif)
struct rman *rm;
TAILQ_FOREACH(rm, &rman_head, rm_link) {
- if ((void *)rm == (void *)rm)
+ if ((void *)rm == (void *)addr)
return (0);
}