Improve selnl_msglen() function.

This commit is contained in:
Yousha Aleayoub 2024-02-29 13:09:10 +03:30 committed by GitHub
parent 805d849d7c
commit 40f3011a6b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -35,8 +35,10 @@ static int selnl_msglen(int msgtype)
break;
default:
BUG();
pr_err("Unknown message type in selnl_msglen: %d\n", msgtype);
ret = -EINVAL; // Return an error code or appropriate default value
}
return ret;
}