Skip to contentSkip to conversation

ocfs2: fix a redundant re-initialization

PATCH New [email protected] 1 participant 1 message Jul 26, 2016 OCFS2

lore
Share & tools
lore
#0 lore raw

PATCH 11/126 ocfs2: fix a redundant re-initialization

From: Eric Ren <[email protected]>
Subject: ocfs2: fix a redundant re-initialization

Obviously, memset() has zeroed the whole struct locking_max_version. So, it's no need to zero its two fields individually.

---

 fs/ocfs2/stackglue.c |    2 --
 1 file changed, 2 deletions(-)
fs/ocfs2/stackglue.c renamed from fs/ocfs2/stackglue.c~ocfs2-fix-a-redundant-re-initialization +0 -2
diff -puN fs/ocfs2/stackglue.c~ocfs2-fix-a-redundant-re-initialization fs/ocfs2/stackglue.c
@@ -735,8 +735,6 @@ static void __exit ocfs2_stack_glue_exit
 {
 	memset(&locking_max_version, 0,
 	       sizeof(struct ocfs2_protocol_version));
-	locking_max_version.pv_major = 0;
-	locking_max_version.pv_minor = 0;
 	ocfs2_sysfs_exit();
 	if (ocfs2_table_header)
 		unregister_sysctl_table(ocfs2_table_header);

_