linux: Fix a typo in linux_recvmsg_common

We are supposed to check the result of bsd_to_linux_sockopt_level here
rather than its input.

(cherry picked from commit 9f55630b8d72602f6ec86b15b607f5fc5fde911e)
This commit is contained in:
Alex S 2025-03-10 11:12:36 -07:00 committed by Gleb Smirnoff
parent eca3c0515b
commit a5918bfbf9

View file

@ -1856,7 +1856,7 @@ linux_recvmsg_common(struct thread *td, l_int s, struct l_msghdr *msghdr,
lcm->cmsg_level = bsd_to_linux_sockopt_level(cm->cmsg_level);
if (lcm->cmsg_type == -1 ||
cm->cmsg_level == -1) {
lcm->cmsg_level == -1) {
LINUX_RATELIMIT_MSG_OPT2(
"unsupported recvmsg cmsg level %d type %d",
cm->cmsg_level, cm->cmsg_type);