Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/net Do not reference ifp->if_data directly; use if_expor...
details: https://anonhg.NetBSD.org/src/rev/97a9d3bbb3a5
branches: trunk
changeset: 744288:97a9d3bbb3a5
user: thorpej <thorpej%NetBSD.org@localhost>
date: Wed Jan 29 04:35:13 2020 +0000
description:
Do not reference ifp->if_data directly; use if_export_if_data().
diffstat:
sys/net/rtsock.c | 6 +++---
sys/net/rtsock_shared.c | 6 +++---
2 files changed, 6 insertions(+), 6 deletions(-)
diffs (54 lines):
diff -r c4a0d898af79 -r 97a9d3bbb3a5 sys/net/rtsock.c
--- a/sys/net/rtsock.c Wed Jan 29 04:28:27 2020 +0000
+++ b/sys/net/rtsock.c Wed Jan 29 04:35:13 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rtsock.c,v 1.252 2019/09/01 18:54:38 roy Exp $ */
+/* $NetBSD: rtsock.c,v 1.253 2020/01/29 04:35:13 thorpej Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -61,7 +61,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rtsock.c,v 1.252 2019/09/01 18:54:38 roy Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rtsock.c,v 1.253 2020/01/29 04:35:13 thorpej Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -239,7 +239,7 @@
ifm = (struct if_xmsghdr *)w->w_tmem;
ifm->ifm_index = ifp->if_index;
ifm->ifm_flags = ifp->if_flags;
- ifm->ifm_data = ifp->if_data;
+ if_export_if_data(ifp, &ifm->ifm_data, false);
ifm->ifm_addrs = info->rti_addrs;
if ((error = copyout(ifm, w->w_where, len)) == 0)
w->w_where = (char *)w->w_where + len;
diff -r c4a0d898af79 -r 97a9d3bbb3a5 sys/net/rtsock_shared.c
--- a/sys/net/rtsock_shared.c Wed Jan 29 04:28:27 2020 +0000
+++ b/sys/net/rtsock_shared.c Wed Jan 29 04:35:13 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rtsock_shared.c,v 1.11 2019/10/14 16:43:04 maxv Exp $ */
+/* $NetBSD: rtsock_shared.c,v 1.12 2020/01/29 04:35:13 thorpej Exp $ */
/*
* Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -61,7 +61,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rtsock_shared.c,v 1.11 2019/10/14 16:43:04 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rtsock_shared.c,v 1.12 2020/01/29 04:35:13 thorpej Exp $");
#ifdef _KERNEL_OPT
#include "opt_inet.h"
@@ -1348,7 +1348,7 @@
(void)memset(&ifm, 0, sizeof(ifm));
ifm.ifm_index = ifp->if_index;
ifm.ifm_flags = ifp->if_flags;
- ifm.ifm_data = ifp->if_data;
+ if_export_if_data(ifp, &ifm.ifm_data, false);
ifm.ifm_addrs = 0;
m = COMPATNAME(rt_msg1)(RTM_IFINFO, &info, &ifm, sizeof(ifm));
if (m == NULL)
Home |
Main Index |
Thread Index |
Old Index