git: 48f33b55b014 - main - netlink: fix casts
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 28 Feb 2024 22:27:12 UTC
The branch main has been updated by kp: URL: https://cgit.FreeBSD.org/src/commit/?id=48f33b55b0148c3c8991e53156f37c42b8bc22e9 commit 48f33b55b0148c3c8991e53156f37c42b8bc22e9 Author: Kristof Provost <kp@FreeBSD.org> AuthorDate: 2024-02-26 10:18:30 +0000 Commit: Kristof Provost <kp@FreeBSD.org> CommitDate: 2024-02-28 22:26:17 +0000 netlink: fix casts Reviewed by: melifaro MFC after: 1 week Sponsored by: Rubicon Communications, LLC ("Netgate") Differential Revision: https://reviews.freebsd.org/D44088 --- sys/netlink/netlink_message_parser.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/netlink/netlink_message_parser.c b/sys/netlink/netlink_message_parser.c index 4440f8df2df2..8caa13fbf3ce 100644 --- a/sys/netlink/netlink_message_parser.c +++ b/sys/netlink/netlink_message_parser.c @@ -321,7 +321,7 @@ nlattr_get_uint8(struct nlattr *nla, struct nl_pstate *npt, const void *arg, voi nla->nla_type, NLA_DATA_LEN(nla)); return (EINVAL); } - *((uint16_t *)target) = *((const uint16_t *)NL_RTA_DATA_CONST(nla)); + *((uint8_t *)target) = *((const uint8_t *)NL_RTA_DATA_CONST(nla)); return (0); }