From: Chuck Lever Date: Sat, 6 Dec 2008 00:03:01 +0000 (-0500) Subject: NSM: Remove NULL pointer check from nsm_find() X-Git-Tag: v2.6.29-rc1~177^2~38 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=bc1cc6c4e476b60df48227165990c87a22db6bb7;p=linux-2.6-omap-h63xx.git 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: Chuck Lever Signed-off-by: J. Bruce Fields --- diff --git a/fs/lockd/mon.c b/fs/lockd/mon.c index 38255455563..0a066a13478 100644 --- a/fs/lockd/mon.c +++ b/fs/lockd/mon.c @@ -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\" "