git: 21ad3e27fabc - main - jail: Fix output of IPv[46] addresses of DDB `show prison`
Date: Wed, 21 Dec 2022 01:58:49 UTC
The branch main has been updated by zlei: URL: https://cgit.FreeBSD.org/src/commit/?id=21ad3e27fabcdc3088be993e67e3bc12bd237398 commit 21ad3e27fabcdc3088be993e67e3bc12bd237398 Author: Zhenlei Huang <zlei@FreeBSD.org> AuthorDate: 2022-12-21 01:53:28 +0000 Commit: Zhenlei Huang <zlei@FreeBSD.org> CommitDate: 2022-12-21 01:53:28 +0000 jail: Fix output of IPv[46] addresses of DDB `show prison` Reviewed by: melifaro, jamie Approved by: kp (mentor) Fixes: eb8dcdeac22d jail: network epoch protection for IP address lists Differential Revision: https://reviews.freebsd.org/D37732 --- sys/kern/kern_jail.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/kern/kern_jail.c b/sys/kern/kern_jail.c index 705d90aecdf8..c715dbf25977 100644 --- a/sys/kern/kern_jail.c +++ b/sys/kern/kern_jail.c @@ -4919,7 +4919,7 @@ db_show_prison(struct prison *pr) db_printf(" %s %s\n", ii == 0 ? "ip4.addr =" : " ", inet_ntoa_r( - *(const struct in_addr *)PR_IP(pr, ii), + *(const struct in_addr *)PR_IP(pr->pr_addrs[af], ii), ip4buf)); } #endif @@ -4932,7 +4932,7 @@ db_show_prison(struct prison *pr) db_printf(" %s %s\n", ii == 0 ? "ip6.addr =" : " ", ip6_sprintf(ip6buf, - (const struct in6_addr *)PR_IP(pr, ii))); + (const struct in6_addr *)PR_IP(pr->pr_addrs[af], ii))); } #endif }