Whamcloud - gitweb
LU-5310 build: fix build error in Centos 7 35/11035/2
authorBob Glossman <bob.glossman@intel.com>
Wed, 9 Jul 2014 21:03:18 +0000 (14:03 -0700)
committerOleg Drokin <oleg.drokin@intel.com>
Thu, 10 Jul 2014 17:07:29 +0000 (17:07 +0000)
Fix a code flaw added to master by recent commit
de2d5808bd2987f76d2486272e1a9c192ba277d4.
Causes a build failure in newer version gcc v4.8.2 used in Centos 7.

Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Change-Id: Icc0aa1994ece756cd70bc5d69101cbe1694f8df0
Reviewed-on: http://review.whamcloud.com/11035
Reviewed-by: James Simmons <uja.ornl@gmail.com>
Tested-by: Jenkins
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Dmitry Eremin <dmitry.eremin@intel.com>
lustre/mdd/mdd_dir.c

index 0262646..49389e0 100644 (file)
@@ -3393,7 +3393,7 @@ static int mdd_migrate_create(const struct lu_env *env,
        }
 
        mgr_ea = (struct lmv_mds_md_v1 *)info->mti_xattr_buf;
-       memset(mgr_ea, 0, sizeof(mgr_ea));
+       memset(mgr_ea, 0, sizeof(*mgr_ea));
        mgr_ea->lmv_magic = cpu_to_le32(LMV_MAGIC_V1);
        mgr_ea->lmv_stripe_count = cpu_to_le32(2);
        mgr_ea->lmv_master_mdt_index = mdd_seq_site(mdd)->ss_node_id;