提交 bc1cc6c4 编写于 作者: C Chuck Lever 提交者: J. Bruce Fields

NSM: Remove NULL pointer check from nsm_find()

The nsm_find() function should never be called with a NULL IP address
pointer.  If it is, that's a bug.
Signed-off-by: NChuck Lever <chuck.lever@oracle.com>
Signed-off-by: NJ. Bruce Fields <bfields@citi.umich.edu>
上级 5cf1c4b1
......@@ -224,9 +224,6 @@ struct nsm_handle *nsm_find(const struct sockaddr *sap, const size_t salen,
struct nsm_handle *nsm = NULL;
struct nsm_handle *pos;
if (!sap)
return NULL;
if (hostname && memchr(hostname, '/', hostname_len) != NULL) {
if (printk_ratelimit()) {
printk(KERN_WARNING "Invalid hostname \"%.*s\" "
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册