summaryrefslogtreecommitdiff
path: root/usr/src/uts/common/fs/nfs/nfs4_state.c
diff options
context:
space:
mode:
authorJosef 'Jeff' Sipek <jeffpc@josefsipek.net>2016-02-24 11:58:55 -0500
committerRobert Mustacchi <rm@joyent.com>2016-02-27 08:52:10 -0800
commitaab83bb83be7342f6cfccaed8d5fe0b2f404855d (patch)
tree548e8760643ee94860fb29486fbf965675c52a59 /usr/src/uts/common/fs/nfs/nfs4_state.c
parentd643a855cbd8c4fb4fe966406fa05dff70673597 (diff)
downloadillumos-gate-aab83bb83be7342f6cfccaed8d5fe0b2f404855d.tar.gz
6659 nvlist_free(NULL) is a no-op
Reviewed by: Toomas Soome <tsoome@me.com> Reviewed by: Marcel Telka <marcel@telka.sk> Approved by: Robert Mustacchi <rm@joyent.com>
Diffstat (limited to 'usr/src/uts/common/fs/nfs/nfs4_state.c')
-rw-r--r--usr/src/uts/common/fs/nfs/nfs4_state.c9
1 files changed, 3 insertions, 6 deletions
diff --git a/usr/src/uts/common/fs/nfs/nfs4_state.c b/usr/src/uts/common/fs/nfs/nfs4_state.c
index 9f743caf70..47941454bc 100644
--- a/usr/src/uts/common/fs/nfs/nfs4_state.c
+++ b/usr/src/uts/common/fs/nfs/nfs4_state.c
@@ -1066,8 +1066,7 @@ rfs4_dss_setpaths(char *buf, size_t buflen)
* Before we lose the ptr, destroy the nvlist and pathnames
* array from the warm start before this one.
*/
- if (rfs4_dss_oldpaths)
- nvlist_free(rfs4_dss_oldpaths);
+ nvlist_free(rfs4_dss_oldpaths);
rfs4_dss_oldpaths = rfs4_dss_paths;
}
@@ -1465,10 +1464,8 @@ rfs4_state_fini()
rfs4_seen_first_compound = 0;
/* DSS: distributed stable storage */
- if (rfs4_dss_oldpaths)
- nvlist_free(rfs4_dss_oldpaths);
- if (rfs4_dss_paths)
- nvlist_free(rfs4_dss_paths);
+ nvlist_free(rfs4_dss_oldpaths);
+ nvlist_free(rfs4_dss_paths);
rfs4_dss_paths = rfs4_dss_oldpaths = NULL;
}