NFS: fix the return value check by using IS_ERR
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / fs / nfs / nfs4namespace.c
index 017b4b01a69c7a747b4afab8c7591b5f2ac59a20..398d5fd741575db80757a00244fa307728c6c3ee 100644 (file)
@@ -205,7 +205,7 @@ struct rpc_clnt *nfs4_create_sec_client(struct rpc_clnt *clnt, struct inode *ino
                return clone;
 
        auth = rpcauth_create(flavor, clone);
-       if (!auth) {
+       if (IS_ERR(auth)) {
                rpc_shutdown_client(clone);
                clone = ERR_PTR(-EIO);
        }