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

NSM: Remove !nsm check from nsm_release()

The nsm_release() function should never be called with a NULL handle
point.  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>
上级 bc1cc6c4
......@@ -288,8 +288,6 @@ struct nsm_handle *nsm_find(const struct sockaddr *sap, const size_t salen,
*/
void nsm_release(struct nsm_handle *nsm)
{
if (!nsm)
return;
if (atomic_dec_and_lock(&nsm->sm_count, &nsm_lock)) {
list_del(&nsm->sm_link);
spin_unlock(&nsm_lock);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册