[fedfs-utils] [PATCH 8/9] nfsref: Remove redundant check for nce == NULL
Chuck Lever
chuck.lever at oracle.com
Fri Jun 27 11:43:19 PDT 2014
If nfsref_remove_delete_fsn() is called with a NULL nce argument,
nsdb_default_nce is substituted. If there is no default, then the
function returns.
Thus a later check for nce == NULL is not necessary.
Fixes: d4550c62 (nfsref: "nfsref remove" should remove FSN found
in junction)
Signed-off-by: Chuck Lever <chuck.lever at oracle.com>
---
src/nfsref/remove.c | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/src/nfsref/remove.c b/src/nfsref/remove.c
index 162a04c9a7be..686fc00dd640 100644
--- a/src/nfsref/remove.c
+++ b/src/nfsref/remove.c
@@ -176,11 +176,7 @@ nfsref_remove_delete_fsn(const char *junct_path)
fsn_uuid, nce);
break;
case FEDFS_ERR_NSDB_NONCE:
- if (nce == NULL)
- xlog(L_ERROR, "NSDB %s:%u has no NCE",
- nsdb_hostname(host), nsdb_port(host));
- else
- xlog(L_ERROR, "NCE %s does not exist", nce);
+ xlog(L_ERROR, "NCE %s does not exist", nce);
break;
case FEDFS_ERR_NSDB_NOFSN:
xlog(L_ERROR, "NSDB %s:%u has no such FSN %s",
More information about the fedfs-utils-devel
mailing list